fix clippy::single_char_pattern perf findings
This commit is contained in:
@@ -335,7 +335,7 @@ fn build_options<O: Default>(
|
||||
Some((k, v)) => (k.to_string(), Some(v)),
|
||||
};
|
||||
|
||||
let option_to_lookup = key.replace("-", "_");
|
||||
let option_to_lookup = key.replace('-', "_");
|
||||
match descrs.iter().find(|(name, ..)| *name == option_to_lookup) {
|
||||
Some((_, setter, type_desc, _)) => {
|
||||
if !setter(&mut op, value) {
|
||||
|
||||
Reference in New Issue
Block a user