Fix clippy lint
#[warn(clippy::single_match)]
@@ -325,8 +325,7 @@ pub fn parse<'f>(format_string: &'f str) -> Result<Vec<Fragment<'f>>, Cow<'stati
// Check for argument type conflicts.
let mut args = Vec::new();
for frag in &fragments {
- match frag {
- Fragment::Parameter(Parameter { index, ty }) => {
+ if let Fragment::Parameter(Parameter { index, ty }) = frag {
if args.len() <= *index {
args.resize(*index + 1, None);
}
@@ -351,8 +350,6 @@ pub fn parse<'f>(format_string: &'f str) -> Result<Vec<Fragment<'f>>, Cow<'stati
}
}
}
- _ => {}
- }
}
// Check that argument indices are dense (all arguments must be used).
