]> git.lizzy.rs Git - rust.git/blob - src/test/ui/pattern/usefulness/stable-gated-patterns.rs
Rollup merge of #89468 - FabianWolff:issue-89358, r=jackh726
[rust.git] / src / test / ui / pattern / usefulness / stable-gated-patterns.rs
1 // aux-build:unstable.rs
2
3 extern crate unstable;
4
5 use unstable::Foo;
6
7 fn main() {
8     match Foo::Stable {
9         Foo::Stable => {}
10     }
11     //~^^^ non-exhaustive patterns: `Stable2` and `_` not covered
12
13     match Foo::Stable {
14         Foo::Stable => {}
15         Foo::Stable2 => {}
16     }
17     //~^^^^ non-exhaustive patterns: `_` not covered
18 }