summaryrefslogtreecommitdiffstats
path: root/tests/ui/type-alias-impl-trait/missing_lifetime_bound.rs
blob: c584a58cb32e7f6556a298132cd8c6af7de0637a (plain)
1
2
3
4
5
6
7
8
#![feature(type_alias_impl_trait)]

type Opaque2<T> = impl Sized;
type Opaque<'a, T> = Opaque2<T>;
fn defining<'a, T>(x: &'a i32) -> Opaque<T> { x }
//~^ ERROR: hidden type for `Opaque2<T>` captures lifetime that does not appear in bounds

fn main() {}