2018-08-08 07:28:26 -05:00
|
|
|
error[E0072]: recursive type `U` has infinite size
|
2022-06-30 09:17:49 -05:00
|
|
|
--> $DIR/union-nonrepresentable.rs:1:1
|
2018-08-08 07:28:26 -05:00
|
|
|
|
|
2019-03-09 06:03:44 -06:00
|
|
|
LL | union U {
|
2022-08-15 14:11:11 -05:00
|
|
|
| ^^^^^^^
|
2018-08-08 07:28:26 -05:00
|
|
|
LL | a: u8,
|
2022-06-29 21:33:18 -05:00
|
|
|
LL | b: std::mem::ManuallyDrop<U>,
|
2022-08-15 14:11:11 -05:00
|
|
|
| - recursive without indirection
|
2018-08-08 07:28:26 -05:00
|
|
|
|
|
2022-08-15 14:11:11 -05:00
|
|
|
help: insert some indirection (e.g., a `Box`, `Rc`, or `&`) to break the cycle
|
2020-05-29 11:24:59 -05:00
|
|
|
|
|
2022-08-15 14:11:11 -05:00
|
|
|
LL | b: std::mem::ManuallyDrop<Box<U>>,
|
|
|
|
| ++++ +
|
2018-08-08 07:28:26 -05:00
|
|
|
|
|
|
|
error: aborting due to previous error
|
|
|
|
|
|
|
|
For more information about this error, try `rustc --explain E0072`.
|