2019-01-06 09:33:05 -06:00
|
|
|
trait Trait<'a> {}
|
2017-04-04 17:12:53 -05:00
|
|
|
|
|
|
|
fn f<T: (Copy) + (?Sized) + (for<'a> Trait<'a>)>() {}
|
|
|
|
|
|
|
|
fn main() {
|
|
|
|
let _: Box<(Copy) + (?Sized) + (for<'a> Trait<'a>)>;
|
2019-01-06 09:33:05 -06:00
|
|
|
//~^ ERROR `?Trait` is not permitted in trait object types
|
2017-04-04 17:12:53 -05:00
|
|
|
let _: Box<(?Sized) + (for<'a> Trait<'a>) + (Copy)>;
|
|
|
|
let _: Box<(for<'a> Trait<'a>) + (Copy) + (?Sized)>;
|
2019-01-06 09:33:05 -06:00
|
|
|
//~^ ERROR `?Trait` is not permitted in trait object types
|
|
|
|
//~| ERROR use of undeclared lifetime name `'a`
|
2017-04-04 17:12:53 -05:00
|
|
|
}
|