Struct bittle::LittleEndian
source · #[non_exhaustive]pub struct LittleEndian;
Expand description
Little-endian indexing for bit sets.
This can be used in combination with methods such as Bits::test_bit_in
.
Little-endian indexing is constructed increasingly from left to right for
individual primitives, such as the following u8
literal:
0b0010_0010u8
^ ^- index 6
'------ index 2
Arrays are treated the same as expected where the index grows from smallest to largest address:
0 --------- 8 8 -------- 15
[0b0010_0010u8, 0b1000_0000u8]
^ ^ ^- index 8
| '--------- index 6
'-------------- index 2
Trait Implementations§
impl Endian for LittleEndian
Auto Trait Implementations§
impl Freeze for LittleEndian
impl RefUnwindSafe for LittleEndian
impl Send for LittleEndian
impl Sync for LittleEndian
impl Unpin for LittleEndian
impl UnwindSafe for LittleEndian
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more