The bounds on the by argument for the methods BitSlice::shift_start and BitSlice::shift_end are incorrectly documented.
The documentation states that "This panics if by is not less than self.len()." when in fact it should be "less than or equal", as stated correctly just above.
The assert message has the same error.
The following program shows clearly what the actual behaviour is
use bitvec::array::BitArray;
fn main() {
let mut array = BitArray::<u8>::new(52);
print!("{:?}", array);
let len = array.len();
array.shift_left(len);
println!("{:?}", array);
}
I've created PR #251 to fix this