File tree Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Original file line number Diff line number Diff line change @@ -76,7 +76,10 @@ pub fn cli() -> App {
76
76
Arg :: with_name ( "clippy" )
77
77
. long ( "clippy" )
78
78
. help ( "Get fix suggestions from clippy instead of rustc" )
79
- . hidden ( true ) ,
79
+ . hidden ( true )
80
+ . multiple ( true )
81
+ . min_values ( 0 )
82
+ . number_of_values ( 1 ) ,
80
83
)
81
84
. after_help (
82
85
"\
@@ -134,11 +137,13 @@ pub fn exec(config: &mut Config, args: &ArgMatches<'_>) -> CliResult {
134
137
let use_clippy = args. is_present ( "clippy" ) ;
135
138
136
139
let clippy_args = args
137
- . value_of ( "clippy" ) // always yields None
140
+ . value_of ( "clippy" )
138
141
. map ( |s| s. split ( ' ' ) . map ( |s| s. to_string ( ) ) . collect ( ) )
139
142
. or_else ( || Some ( vec ! [ ] ) )
140
143
. filter ( |_| use_clippy) ;
141
144
145
+ // dbg!(&clippy_args, use_clippy);
146
+
142
147
if use_clippy && !config. cli_unstable ( ) . unstable_options {
143
148
return Err ( failure:: format_err!(
144
149
"`cargo fix --clippy` is unstable, pass `-Z unstable-options` to enable it"
You can’t perform that action at this time.
0 commit comments