mirror of
https://github.com/rust-lang/rust.git
synced 2024-10-31 06:22:00 +00:00
cf6d6050f7
* The WASI targets deal with the `main` symbol a bit differently than native so some `codegen` and `assembly` tests have been ignored. * All `ignore-emscripten` directives have been updated to `ignore-wasm32` to be more clear that all wasm targets are ignored and it's not just Emscripten. * Most `ignore-wasm32-bare` directives are now gone. * Some ignore directives for wasm were switched to `needs-unwind` instead. * Many `ignore-wasm32*` directives are removed as the tests work with WASI as opposed to `wasm32-unknown-unknown`.
31 lines
1.4 KiB
Rust
31 lines
1.4 KiB
Rust
// This tests that optimized enum debug info accurately reflects the enum layout.
|
|
// This is ignored for the fallback mode on MSVC due to problems with PDB.
|
|
|
|
//@ ignore-msvc
|
|
//@ ignore-wasi wasi codegens the main symbol differently
|
|
|
|
//@ compile-flags: -g -C no-prepopulate-passes
|
|
|
|
// CHECK-LABEL: @main
|
|
// CHECK: {{.*}}DICompositeType{{.*}}tag: DW_TAG_variant_part,{{.*}}discriminator:{{.*}}
|
|
// CHECK: {{.*}}DIDerivedType{{.*}}tag: DW_TAG_member,{{.*}}name: "A",{{.*}}extraData:{{.*}}
|
|
// CHECK: {{.*}}DICompositeType{{.*}}tag: DW_TAG_structure_type,{{.*}}name: "A",{{.*}}
|
|
// CHECK: {{.*}}DIDerivedType{{.*}}tag: DW_TAG_member,{{.*}}name: "B",{{.*}}extraData:{{.*}}
|
|
// CHECK: {{.*}}DICompositeType{{.*}}tag: DW_TAG_structure_type,{{.*}}name: "B",{{.*}}
|
|
// CHECK: {{.*}}DIDerivedType{{.*}}tag: DW_TAG_member,{{.*}}name: "C",{{.*}}extraData:{{.*}}
|
|
// CHECK: {{.*}}DICompositeType{{.*}}tag: DW_TAG_structure_type,{{.*}}name: "C",{{.*}}
|
|
// CHECK-NOT: {{.*}}DIDerivedType{{.*}}name: "D",{{.*}}extraData:{{.*}}
|
|
// CHECK: {{.*}}DIDerivedType{{.*}}tag: DW_TAG_member,{{.*}}name: "D",{{.*}}
|
|
// CHECK: {{.*}}DICompositeType{{.*}}tag: DW_TAG_structure_type,{{.*}}name: "D",{{.*}}
|
|
// CHECK: {{.*}}DIDerivedType{{.*}}tag: DW_TAG_member,{{.*}}flags: DIFlagArtificial{{.*}}
|
|
|
|
#![allow(dead_code)]
|
|
#![allow(unused_variables)]
|
|
#![allow(unused_assignments)]
|
|
|
|
enum E { A, B, C, D(bool) }
|
|
|
|
pub fn main() {
|
|
let e = E::D(true);
|
|
}
|