1 // Make sure that we check that impl trait types implement the traits that they
4 #![feature(type_alias_impl_trait)]
6 type X<'a> = impl Into<&'static str> + From<&'a str>;
8 fn f<'a: 'static>(t: &'a str) -> X<'a> {
9 //~^ WARNING unnecessary lifetime parameter
11 //~^ ERROR non-defining opaque type use
14 fn extend_lt<'a>(o: &'a str) -> &'static str {
15 X::<'_>::from(o).into()
20 let s = "abcdef".to_string();