]> git.lizzy.rs Git - rust.git/blob - tests/ui/unsized/unsized-trait-impl-trait-arg.rs
Auto merge of #107843 - bjorn3:sync_cg_clif-2023-02-09, r=bjorn3
[rust.git] / tests / ui / unsized / unsized-trait-impl-trait-arg.rs
1 // Test sized-ness checking in substitution in impls.
2
3 // impl - unbounded
4 trait T2<Z> {
5     fn foo(&self, z: Z);
6 }
7 struct S4<Y: ?Sized>(Box<Y>);
8 impl<X: ?Sized> T2<X> for S4<X> {
9     //~^ ERROR the size for values of type
10 }
11
12 fn main() { }