rust/tests/ui/pattern/usefulness/issue-31561.rs
2023-01-11 09:32:08 +00:00

11 lines
192 B
Rust

enum Thing {
Foo(u8),
Bar,
Baz
}
fn main() {
let Thing::Foo(y) = Thing::Foo(1);
//~^ ERROR refutable pattern in local binding: `Thing::Bar` and `Thing::Baz` not covered
}