1
Fork 0
rust/src/test/ui/pattern/usefulness/stable-gated-patterns.rs

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

19 lines
397 B
Rust
Raw Normal View History

// aux-build:unstable.rs
extern crate unstable;
use unstable::UnstableEnum;
fn main() {
match UnstableEnum::Stable {
UnstableEnum::Stable => {}
}
//~^^^ non-exhaustive patterns: `Stable2` and `_` not covered
match UnstableEnum::Stable {
UnstableEnum::Stable => {}
UnstableEnum::Stable2 => {}
}
//~^^^^ non-exhaustive patterns: `_` not covered
}