#[repr(u8)]pub enum U4 {
Show 16 variants
B0000 = 0,
B0001 = 1,
B0010 = 2,
B0011 = 3,
B0100 = 4,
B0101 = 5,
B0110 = 6,
B0111 = 7,
B1000 = 8,
B1001 = 9,
B1010 = 10,
B1011 = 11,
B1100 = 12,
B1101 = 13,
B1110 = 14,
B1111 = 15,
}
Variants§
B0000 = 0
B0001 = 1
B0010 = 2
B0011 = 3
B0100 = 4
B0101 = 5
B0110 = 6
B0111 = 7
B1000 = 8
B1001 = 9
B1010 = 10
B1011 = 11
B1100 = 12
B1101 = 13
B1110 = 14
B1111 = 15
Implementations§
Source§impl U4
impl U4
Sourcepub unsafe fn from_u8_unchecked(other: u8) -> Self
pub unsafe fn from_u8_unchecked(other: u8) -> Self
Constructs the value without a range check.
Sourcepub unsafe fn from_u16_unchecked(other: u16) -> Self
pub unsafe fn from_u16_unchecked(other: u16) -> Self
Constructs the value without a range check.
Sourcepub unsafe fn from_u32_unchecked(other: u32) -> Self
pub unsafe fn from_u32_unchecked(other: u32) -> Self
Constructs the value without a range check.
Sourcepub unsafe fn from_usize_unchecked(other: usize) -> Self
pub unsafe fn from_usize_unchecked(other: usize) -> Self
Constructs the value without a range check.
Sourcepub fn into_usize(self) -> usize
pub fn into_usize(self) -> usize
Returns the value as an usize.
Trait Implementations§
impl Copy for U4
impl Eq for U4
impl StructuralPartialEq for U4
Auto Trait Implementations§
impl Freeze for U4
impl RefUnwindSafe for U4
impl Send for U4
impl Sync for U4
impl Unpin for U4
impl UnwindSafe for U4
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