rust/tests/ui/generic-associated-types/issue-67510.rs

11 lines
244 B
Rust

trait X {
type Y<'a>;
}
fn f(x: Box<dyn X<Y<'a> = &'a ()>>) {}
//~^ ERROR: use of undeclared lifetime name `'a`
//~| ERROR: use of undeclared lifetime name `'a`
//~| ERROR: the trait `X` cannot be made into an object [E0038]
fn main() {}