Update for changes to other lints
This commit is contained in:
parent
fa10d90b99
commit
1c31a95df7
1 changed files with 14 additions and 9 deletions
|
@ -102,17 +102,22 @@ LL | #[warn(non_exhaustive_omitted_patterns)]
|
||||||
error[E0004]: non-exhaustive patterns: `C` not covered
|
error[E0004]: non-exhaustive patterns: `C` not covered
|
||||||
--> $DIR/feature-gate-non_exhaustive_omitted_patterns_lint.rs:20:11
|
--> $DIR/feature-gate-non_exhaustive_omitted_patterns_lint.rs:20:11
|
||||||
|
|
|
|
||||||
LL | / enum Foo {
|
LL | match Foo::A {
|
||||||
LL | | A, B, C,
|
| ^^^^^^ pattern `C` not covered
|
||||||
| | - not covered
|
|
||||||
LL | | }
|
|
||||||
| |_____- `Foo` defined here
|
|
||||||
...
|
|
||||||
LL | match Foo::A {
|
|
||||||
| ^^^^^^ pattern `C` not covered
|
|
||||||
|
|
|
|
||||||
= help: ensure that all possible cases are being handled, possibly by adding wildcards or more match arms
|
note: `Foo` defined here
|
||||||
|
--> $DIR/feature-gate-non_exhaustive_omitted_patterns_lint.rs:12:15
|
||||||
|
|
|
||||||
|
LL | enum Foo {
|
||||||
|
| ---
|
||||||
|
LL | A, B, C,
|
||||||
|
| ^ not covered
|
||||||
= note: the matched value is of type `Foo`
|
= note: the matched value is of type `Foo`
|
||||||
|
help: ensure that all possible cases are being handled by adding a match arm with a wildcard pattern or an explicit pattern as shown
|
||||||
|
|
|
||||||
|
LL ~ Foo::B => {}
|
||||||
|
LL + C => todo!()
|
||||||
|
|
|
||||||
|
|
||||||
error: aborting due to previous error; 10 warnings emitted
|
error: aborting due to previous error; 10 warnings emitted
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue