File tree 1 file changed +6
-6
lines changed
1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -335,10 +335,10 @@ pub struct RustcDefaultCalls;
335
335
fn handle_explain ( code : & str ,
336
336
descriptions : & diagnostics:: registry:: Registry ,
337
337
output : ErrorOutputType ) {
338
- let normalised = if !code. starts_with ( "E" ) {
339
- format ! ( "E{0:0>4}" , code)
340
- } else {
338
+ let normalised = if code. starts_with ( "E" ) {
341
339
code. to_string ( )
340
+ } else {
341
+ format ! ( "E{0:0>4}" , code)
342
342
} ;
343
343
match descriptions. find_description ( & normalised) {
344
344
Some ( ref description) => {
@@ -916,10 +916,10 @@ pub fn handle_options(args: &[String]) -> Option<getopts::Matches> {
916
916
if opt. stability == OptionStability :: Stable {
917
917
continue
918
918
}
919
- let opt_name = if !opt. opt_group . long_name . is_empty ( ) {
920
- & opt. opt_group . long_name
921
- } else {
919
+ let opt_name = if opt. opt_group . long_name . is_empty ( ) {
922
920
& opt. opt_group . short_name
921
+ } else {
922
+ & opt. opt_group . long_name
923
923
} ;
924
924
if !matches. opt_present ( opt_name) {
925
925
continue
You can’t perform that action at this time.
0 commit comments