Debian Codegraph @

gcc/testsuite/rust/compile/pattern-struct.rs

raw
1 fn main() {
2 enum A {
3 B,
4 C,
5 }
6
7 impl A {
8 fn new() {}
9 }
10
11 fn bar(foo: A) {
12 match foo {
13 A::new() => (),
14 // { dg-error "expected tuple struct or tuple variant, found function" "" { target *-*-* } .-1 }
15 _ => {}
16 }
17 }
18 }