2022-06-30 02:33:18 +00:00
|
|
|
use std::mem::ManuallyDrop;
|
2017-08-16 11:32:41 +00:00
|
|
|
|
|
|
|
union Foo<T: ?Sized> {
|
2022-06-30 02:33:18 +00:00
|
|
|
value: ManuallyDrop<T>,
|
2018-07-10 21:10:13 +00:00
|
|
|
//~^ ERROR the size for values of type
|
2017-08-16 11:32:41 +00:00
|
|
|
}
|
|
|
|
|
2017-08-16 16:45:54 +00:00
|
|
|
struct Foo2<T: ?Sized> {
|
2022-06-30 02:33:18 +00:00
|
|
|
value: ManuallyDrop<T>,
|
2018-07-10 21:10:13 +00:00
|
|
|
//~^ ERROR the size for values of type
|
2017-08-16 16:45:54 +00:00
|
|
|
t: u32,
|
|
|
|
}
|
|
|
|
|
|
|
|
enum Foo3<T: ?Sized> {
|
2022-06-30 02:33:18 +00:00
|
|
|
Value(ManuallyDrop<T>),
|
2018-07-10 21:10:13 +00:00
|
|
|
//~^ ERROR the size for values of type
|
2017-08-16 16:45:54 +00:00
|
|
|
}
|
|
|
|
|
2017-08-16 11:32:41 +00:00
|
|
|
fn main() {}
|