#[repr(transparent)]pub struct u8x2(_);
Expand description
Two u8
values packed as a u16
.
Compared to using [u8; 2]
, this forces the data to have an alignment of 2,
and also keeps volatile reads and writes as a single access (when possible).
Implementations§
Trait Implementations§
source§impl Ord for u8x2
impl Ord for u8x2
source§impl PartialEq<u8x2> for u8x2
impl PartialEq<u8x2> for u8x2
source§impl PartialOrd<u8x2> for u8x2
impl PartialOrd<u8x2> for u8x2
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moreimpl Copy for u8x2
impl Eq for u8x2
impl StructuralEq for u8x2
impl StructuralPartialEq for u8x2
Auto Trait Implementations§
impl RefUnwindSafe for u8x2
impl Send for u8x2
impl Sync for u8x2
impl Unpin for u8x2
impl UnwindSafe for u8x2
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