Skip to content

Commit 9d5482e

Browse files
committed
clippy: block_in_if_condition_stmt
1 parent 35306ed commit 9d5482e

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

src/app/parser.rs

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -868,8 +868,7 @@ impl<'a, 'b> Parser<'a, 'b>
868868
}
869869

870870
if !starts_new_arg {
871-
match needs_val_of {
872-
ParseResult::Opt(name) => {
871+
if let ParseResult::Opt(name) = needs_val_of {
873872
// Check to see if parsing a value from a previous arg
874873
let arg = self.opts
875874
.iter()
@@ -879,8 +878,6 @@ impl<'a, 'b> Parser<'a, 'b>
879878
needs_val_of = try!(self.add_val_to_arg(arg, &arg_os, matcher));
880879
// get the next value from the iterator
881880
continue;
882-
}
883-
_ => (),
884881
}
885882
} else if arg_os.starts_with(b"--") {
886883
needs_val_of = try!(self.parse_long_arg(matcher, &arg_os));

0 commit comments

Comments
 (0)