Skip to content

Commit

Permalink
refactor: simplify
Browse files Browse the repository at this point in the history
  • Loading branch information
GrayJack committed Jan 17, 2025
1 parent f88327d commit f678177
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -488,10 +488,10 @@ pub trait Flags: Sized + Copy + 'static {
let mut truncated = Self::Bits::EMPTY;

for (_, flag) in Self::KNOWN_FLAGS.iter() {
truncated = truncated | flag.bits();
truncated |= flag.bits();
}

truncated = truncated | Self::EXTRA_VALID_BITS;
truncated |= Self::EXTRA_VALID_BITS;

Self::from_bits_retain(truncated)
}
Expand Down

0 comments on commit f678177

Please sign in to comment.