1 #![feature(generic_associated_types)] 2 3 trait ATy { 4 type Item<'a>: 'a; 5 } 6 7 impl<'b> ATy for &'b () { 8 type Item<'a> = &'b (); 9 //~^ ERROR the type `&'b ()` does not fulfill the required lifetime 10 } 11 12 trait StaticTy { 13 type Item<'a>: 'static; 14 } 15 16 impl StaticTy for () { 17 type Item<'a> = &'a (); 18 //~^ ERROR the type `&'a ()` does not fulfill the required lifetime 19 } 20 main()21fn main() {} 22