all: address clippy lints
This commit is contained in:
parent
0fe59effe2
commit
ae991b9038
28 changed files with 84 additions and 70 deletions
|
|
@ -596,11 +596,12 @@ macro_rules! bitflags {
|
|||
}
|
||||
|
||||
impl std::fmt::Debug for $name {
|
||||
#[allow(clippy::bad_bit_mask)]
|
||||
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
|
||||
let mut any = false;
|
||||
let mut v = self.0;
|
||||
$(
|
||||
if v & $val == $val {
|
||||
if $val != 0 && v & $val == $val {
|
||||
if any {
|
||||
write!(f, "|")?;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue