]>
Commit | Line | Data |
---|---|---|
7cac9316 XL |
1 | enum Foo { |
2 | Bar { bar: Bar, id: usize } | |
9e0c209e SL |
3 | } |
4 | ||
7cac9316 XL |
5 | enum Bar { |
6 | A, B, C, D, E, F | |
9e0c209e | 7 | } |
1a4d82fc | 8 | |
7cac9316 XL |
9 | fn test(f: Foo) { |
10 | match f { | |
11 | //~^ ERROR non-exhaustive patterns | |
12 | //~| patterns | |
13 | Foo::Bar { bar: Bar::A, .. } => (), | |
14 | Foo::Bar { bar: Bar::B, .. } => (), | |
15 | } | |
223e47cc | 16 | } |
7cac9316 XL |
17 | |
18 | fn main() {} |