]>
git.proxmox.com Git - rustc.git/blob - src/test/ui/nll/relate_tys/universe-violation.rs
1 // Test that the NLL `relate_tys` code correctly deduces that a
2 // function returning either argument CANNOT be upcast to one
3 // that returns always its first argument.
5 // compile-flags:-Zno-leak-check
9 fn make_it() -> fn(&'
static u32) -> &'
static u32 {
14 let a
: fn(_
) -> _
= make_it();
15 let b
: fn(&u32) -> &u32 = a
;