pub fn new(bytes: &'a [u8], _endianness: E) -> Self {
        let byte_len = bytes.len();

        BitReadBuffer {
            bytes: Data::Borrowed(bytes),
            bit_len: byte_len * 8,
            endianness: PhantomData,
            slice: bytes,
        }
    }
/// Create a new BitBuffer from a byte slice
///
/// # Examples
///
/// ```
/// use bitbuffer::{BitReadBuffer, LittleEndian};
///
/// let bytes = vec![
///     0b1011_0101, 0b0110_1010, 0b1010_1100, 0b1001_1001,
///     0b1001_1001, 0b1001_1001, 0b1001_1001, 0b1110_0111
/// ];
/// let buffer = BitReadBuffer::new(&bytes, LittleEndian);
/// ```
Create a new BitBuffer from a byte slice
Create a new BitBuffer from a byte slice
pub fn new(bytes: &'a [u8], _endianness: E) -> Self {
        let byte_len = bytes.len();
        BitReadBuffer {
            bytes: Data::Borrowed(bytes),
            bit_len: byte_len * 8,
            endianness: PhantomData,
            slice: bytes,
        }
    }
pub fn new ( bytes : & ' a [ u8 ] , _endianness : E ) -> Self { let byte_len = bytes . len ( ) ; BitReadBuffer { bytes : Data :: Borrowed ( bytes ) , bit_len : byte_len * 8 , endianness : PhantomData , slice : bytes , } }
Create a new BitBuffer from a byte slice
Create a new BitBuffer from a byte slice
bytes
&'a [u8]
_endianness
E
bytes
&'a [u8]
_endianness
E
examples
```
use bitbuffer::{BitReadBuffer, LittleEndian}.


` ` ` use bitbuffer :: { BitReadBuffer LittleEndian } .