]>
git.proxmox.com Git - rustc.git/blob - src/test/ui/parser/trait-object-trait-parens.rs
5 fn f
<T
: (Copy
) + (?Sized
) + (for<'a
> Trait
<'a
>)>() {}
8 let _
: Box
<(Obj
) + (?Sized
) + (for<'a
> Trait
<'a
>)>;
9 //~^ ERROR `?Trait` is not permitted in trait object types
10 //~| ERROR only auto traits can be used as additional traits
11 //~| WARN trait objects without an explicit `dyn` are deprecated
12 let _
: Box
<(?Sized
) + (for<'a
> Trait
<'a
>) + (Obj
)>;
13 //~^ ERROR `?Trait` is not permitted in trait object types
14 //~| ERROR only auto traits can be used as additional traits
15 //~| WARN trait objects without an explicit `dyn` are deprecated
16 let _
: Box
<(for<'a
> Trait
<'a
>) + (Obj
) + (?Sized
)>;
17 //~^ ERROR `?Trait` is not permitted in trait object types
18 //~| ERROR only auto traits can be used as additional traits
19 //~| WARN trait objects without an explicit `dyn` are deprecated