blob: a296ae0739fe73cc2ce7a5dc41d24690fd33cef6 [file] [log] [blame]
// Make sure extern types are !Sized.
#![feature(extern_types)]
extern {
type A;
}
struct Foo {
x: u8,
tail: A,
}
struct Bar<T: ?Sized> {
x: u8,
tail: T,
}
fn assert_sized<T>() { }
fn main() {
assert_sized::<A>();
//~^ ERROR the size for values of type
assert_sized::<Foo>();
//~^ ERROR the size for values of type
assert_sized::<Bar<A>>();
//~^ ERROR the size for values of type
assert_sized::<Bar<Bar<A>>>();
//~^ ERROR the size for values of type
}