Closed
Description
We should rewrite this lint as a PreExpansionPass
. We should rewrite a lot of lints as PreExpansionPass
es...
error: you seem to be trying to use match for destructuring a single pattern. Consider using `if let`
--> $DIR/matches.rs:40:5
|
40 | / match tup {
41 | | &(v, 1) => println!("{}", v),
42 | | _ => println!("none"),
43 | | }
| |_____^
help: try this
|
40 | if let &(v, 1) = tup {
41 | # [ cfg ( not ( stage0 ) ) ] {
42 | ( $ crate :: io :: _print ( format_args_nl ! ( $ ( $ arg ) * ) ) ) ; } # [
43 | cfg ( stage0 ) ] { print ! ( "{}/n" , format_args ! ( $ ( $ arg ) * ) ) } } else {
44 | ( $ crate :: io :: _print ( format_args_nl ! ( $ ( $ arg ) * ) ) ) ; }
|