]>
Commit | Line | Data |
---|---|---|
9e0c209e SL |
1 | #[derive(Clone)] |
2 | union U { | |
3 | a: u8 | |
54a0048b | 4 | } |
223e47cc | 5 | |
9e0c209e SL |
6 | #[derive(Clone)] |
7 | union W { | |
29967ef6 | 8 | a: std::mem::ManuallyDrop<String> |
223e47cc | 9 | } |
9e0c209e SL |
10 | |
11 | impl Copy for U {} // OK | |
12 | impl Copy for W {} //~ ERROR the trait `Copy` may not be implemented for this type | |
13 | ||
14 | fn main() {} |