]> git.lizzy.rs Git - rust.git/blob - src/test/ui/union/union-copy.rs
Rollup merge of #103178 - ferrocene:pa-coverage-reports-tests, r=Mark-Simulacrum
[rust.git] / src / test / ui / union / union-copy.rs
1 #[derive(Clone)]
2 union U {
3     a: u8
4 }
5
6 #[derive(Clone)]
7 union W {
8     a: std::mem::ManuallyDrop<String>
9 }
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() {}