Skip to content

Commit

Permalink
Parenthesize color mask thanks to clippy
Browse files Browse the repository at this point in the history
  • Loading branch information
caemor committed Oct 28, 2024
1 parent 6efd6af commit d5c2029
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/color.rs
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ impl ColorType for OctColor {
const BITS_PER_PIXEL_PER_BUFFER: usize = 4;
const BUFFER_COUNT: usize = 1;
fn bitmask(&self, _bwrbit: bool, pos: u32) -> (u8, u16) {
let mask = !(0xF0 >> (pos % 2) * 4);
let mask = !(0xF0 >> ((pos % 2) * 4));
let bits = self.get_nibble() as u16;
(mask, if pos % 2 == 1 { bits } else { bits << 4 })
}
Expand Down

0 comments on commit d5c2029

Please sign in to comment.