diff options
Diffstat (limited to 'gcc/testsuite/rust/compile/issue-3613.rs')
-rw-r--r-- | gcc/testsuite/rust/compile/issue-3613.rs | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/gcc/testsuite/rust/compile/issue-3613.rs b/gcc/testsuite/rust/compile/issue-3613.rs new file mode 100644 index 0000000..f2e1092 --- /dev/null +++ b/gcc/testsuite/rust/compile/issue-3613.rs @@ -0,0 +1,18 @@ +mod m1 { + pub enum Baz4 { + foo1, + foo2, + } +} + +fn bar(x: m1::foo) { + // { dg-error "unknown reference for resolved name: .foo." "" { target *-*-* } .-1 } + match x { + m1::foo::foo1 => {} + // { dg-error "failed to type resolve root segment" "" { target *-*-* } .-1 } + m1::NodePosition::foo2 => {} + // { dg-error "failed to type resolve root segment" "" { target *-*-* } .-1 } + } +} + +pub fn main() {} |