diff --git a/src/bitmap/mutable.rs b/src/bitmap/mutable.rs index 236e9992220..eed57fcdfcd 100644 --- a/src/bitmap/mutable.rs +++ b/src/bitmap/mutable.rs @@ -78,10 +78,8 @@ impl MutableBitmap { if self.length % 8 == 0 { self.buffer.push(0); } - if value { - let byte = self.buffer.as_mut_slice().last_mut().unwrap(); - *byte = set(*byte, self.length % 8, true); - }; + let byte = self.buffer.as_mut_slice().last_mut().unwrap(); + *byte = set(*byte, self.length % 8, value); self.length += 1; }