@@ -872,7 +872,7 @@ Available lint options:
872
872
873
873
let print_lints = |lints : Vec < & Lint > | {
874
874
for lint in lints {
875
- let name = lint. name_lower ( ) . replace ( "_" , "-" ) ;
875
+ let name = lint. name_lower ( ) . replace ( '_' , "-" ) ;
876
876
println ! (
877
877
" {} {:7.7} {}" ,
878
878
padded( & name) ,
@@ -908,10 +908,10 @@ Available lint options:
908
908
909
909
let print_lint_groups = |lints : Vec < ( & ' static str , Vec < LintId > ) > | {
910
910
for ( name, to) in lints {
911
- let name = name. to_lowercase ( ) . replace ( "_" , "-" ) ;
911
+ let name = name. to_lowercase ( ) . replace ( '_' , "-" ) ;
912
912
let desc = to
913
913
. into_iter ( )
914
- . map ( |x| x. to_string ( ) . replace ( "_" , "-" ) )
914
+ . map ( |x| x. to_string ( ) . replace ( '_' , "-" ) )
915
915
. collect :: < Vec < String > > ( )
916
916
. join ( ", " ) ;
917
917
println ! ( " {} {}" , padded( & name) , desc) ;
@@ -960,7 +960,7 @@ fn print_flag_list<T>(
960
960
println ! (
961
961
" {} {:>width$}=val -- {}" ,
962
962
cmdline_opt,
963
- name. replace( "_" , "-" ) ,
963
+ name. replace( '_' , "-" ) ,
964
964
desc,
965
965
width = max_len
966
966
) ;
@@ -1015,7 +1015,7 @@ pub fn handle_options(args: &[String]) -> Option<getopts::Matches> {
1015
1015
. iter ( )
1016
1016
. map ( |& ( name, ..) | ( 'C' , name) )
1017
1017
. chain ( DB_OPTIONS . iter ( ) . map ( |& ( name, ..) | ( 'Z' , name) ) )
1018
- . find ( |& ( _, name) | * opt == name. replace ( "_" , "-" ) )
1018
+ . find ( |& ( _, name) | * opt == name. replace ( '_' , "-" ) )
1019
1019
. map ( |( flag, _) | format ! ( "{}. Did you mean `-{} {}`?" , e, flag, opt) ) ,
1020
1020
_ => None ,
1021
1021
} ;
0 commit comments