rust/src/test/ui/pattern/usefulness/issue-56379.rs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

15 lines
273 B
Rust
Raw Normal View History

2020-12-16 18:42:49 -06:00
enum Foo {
A(bool),
B(bool),
C(bool),
}
fn main() {
match Foo::A(true) {
//~^ ERROR non-exhaustive patterns: `A(false)`, `B(false)` and `C(false)` not covered
2020-12-16 18:42:49 -06:00
Foo::A(true) => {}
Foo::B(true) => {}
Foo::C(true) => {}
}
}