rust/tests/ui/impl-trait/universal_wrong_hrtb.rs

9 lines
212 B
Rust
Raw Normal View History

trait Trait<'a> {
type Assoc;
}
fn test_argument_position(x: impl for<'a> Trait<'a, Assoc = impl Copy + 'a>) {}
//~^ ERROR `impl Trait` can only mention lifetimes bound at the fn or impl level
fn main() {}