diff options
Diffstat (limited to 'src/test/ui/union/union-lint-dead-code.rs')
-rw-r--r-- | src/test/ui/union/union-lint-dead-code.rs | 18 |
1 files changed, 0 insertions, 18 deletions
diff --git a/src/test/ui/union/union-lint-dead-code.rs b/src/test/ui/union/union-lint-dead-code.rs deleted file mode 100644 index 65aaf0a1d..000000000 --- a/src/test/ui/union/union-lint-dead-code.rs +++ /dev/null @@ -1,18 +0,0 @@ -// revisions: mirunsafeck thirunsafeck -// [thirunsafeck]compile-flags: -Z thir-unsafeck - -#![deny(dead_code)] - -union Foo { - x: usize, - b: bool, //~ ERROR: field `b` is never read - _unused: u16, -} - -fn field_read(f: Foo) -> usize { - unsafe { f.x } -} - -fn main() { - let _ = field_read(Foo { x: 2 }); -} |