mirror of
https://github.com/rust-lang/rust-clippy
synced 2024-12-20 18:13:36 +00:00
44 lines
1.7 KiB
Text
44 lines
1.7 KiB
Text
error: wildcard match will also match any future added variants
|
|
--> $DIR/wildcard_enum_match_arm.rs:39:9
|
|
|
|
|
LL | _ => eprintln!("Not red"),
|
|
| ^ help: try: `Color::Green | Color::Blue | Color::Rgb(..) | Color::Cyan`
|
|
|
|
|
note: the lint level is defined here
|
|
--> $DIR/wildcard_enum_match_arm.rs:2:9
|
|
|
|
|
LL | #![deny(clippy::wildcard_enum_match_arm)]
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
error: wildcard match will also match any future added variants
|
|
--> $DIR/wildcard_enum_match_arm.rs:43:9
|
|
|
|
|
LL | _not_red => eprintln!("Not red"),
|
|
| ^^^^^^^^ help: try: `_not_red @ Color::Green | _not_red @ Color::Blue | _not_red @ Color::Rgb(..) | _not_red @ Color::Cyan`
|
|
|
|
error: wildcard match will also match any future added variants
|
|
--> $DIR/wildcard_enum_match_arm.rs:47:9
|
|
|
|
|
LL | not_red => format!("{:?}", not_red),
|
|
| ^^^^^^^ help: try: `not_red @ Color::Green | not_red @ Color::Blue | not_red @ Color::Rgb(..) | not_red @ Color::Cyan`
|
|
|
|
error: wildcard match will also match any future added variants
|
|
--> $DIR/wildcard_enum_match_arm.rs:63:9
|
|
|
|
|
LL | _ => "No red",
|
|
| ^ help: try: `Color::Red | Color::Green | Color::Blue | Color::Rgb(..) | Color::Cyan`
|
|
|
|
error: wildcard matches known variants and will also match future added variants
|
|
--> $DIR/wildcard_enum_match_arm.rs:80:9
|
|
|
|
|
LL | _ => {},
|
|
| ^ help: try: `ErrorKind::PermissionDenied | _`
|
|
|
|
error: wildcard match will also match any future added variants
|
|
--> $DIR/wildcard_enum_match_arm.rs:98:13
|
|
|
|
|
LL | _ => (),
|
|
| ^ help: try: `Enum::B | Enum::__Private`
|
|
|
|
error: aborting due to 6 previous errors
|
|
|