use matches!() macro in more places
This commit is contained in:
parent
c34c015fe2
commit
d12a358673
34 changed files with 138 additions and 270 deletions
|
@ -580,10 +580,7 @@ pub mod printf {
|
|||
}
|
||||
|
||||
fn is_flag(c: &char) -> bool {
|
||||
match c {
|
||||
'0' | '-' | '+' | ' ' | '#' | '\'' => true,
|
||||
_ => false,
|
||||
}
|
||||
matches!(c, '0' | '-' | '+' | ' ' | '#' | '\'')
|
||||
}
|
||||
|
||||
#[cfg(test)]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue