rust/tests/ui/pattern/usefulness/issue-31561.rs

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

12 lines
200 B
Rust
Raw Normal View History

enum Thing {
Foo(u8),
Bar,
Baz
}
fn main() {
let Thing::Foo(y) = Thing::Foo(1);
2022-12-23 14:02:23 -06:00
//~^ ERROR refutable pattern in local binding
//~| `Thing::Bar` and `Thing::Baz` not covered
}