]> git.lizzy.rs Git - rust.git/blob - tests/ui/where-clauses/where-lifetime-resolution.rs
Don't resolve type var roots in point_at_expr_source_of_inferred_type
[rust.git] / tests / ui / where-clauses / where-lifetime-resolution.rs
1 trait Trait1<'a> {}
2 trait Trait2<'a, 'b> {}
3
4 fn f() where
5     for<'a> dyn Trait1<'a>: Trait1<'a>, // OK
6     (dyn for<'a> Trait1<'a>): Trait1<'a>,
7     //~^ ERROR use of undeclared lifetime name `'a`
8     for<'a> dyn for<'b> Trait2<'a, 'b>: Trait2<'a, 'b>,
9     //~^ ERROR use of undeclared lifetime name `'b`
10 {}
11
12 fn main() {}