rust/tests/ui/unsized/unsized-trait-impl-trait-arg.rs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

14 lines
287 B
Rust
Raw Normal View History

// Test sized-ness checking in substitution in impls.
// impl - unbounded
trait T2<Z> {
fn foo(&self, z: Z);
}
struct S4<Y: ?Sized>(Box<Y>);
2015-01-05 21:16:49 +00:00
impl<X: ?Sized> T2<X> for S4<X> {
2018-07-10 21:10:13 +00:00
//~^ ERROR the size for values of type
//~| ERROR not all trait items implemented
}
fn main() { }