1 // build-pass (FIXME(62277): could be check-pass?)
2 // FIXME(#54943) This test targets the scenario where proving the WF requirements requires
3 // knowing the value of the `_` type present in the user type annotation - unfortunately, figuring
4 // out the value of that `_` requires type-checking the surrounding code, but that code is dead,
5 // so our NLL region checker doesn't have access to it. This test should actually fail to compile.
12 fn foo<T: 'static + Debug>(_: T) { }
17 let _x = foo::<Vec<_>>(Vec::<&'a u32>::new());
18 //~^ ERROR the type `&'a u32` does not fulfill the required lifetime [E0477]