#[repr(C, packed(1))]pub struct NonZeroU32_ube(/* private fields */);
Expand description
A big-endian unaligned NonZeroU32
with a guaranteed size of 8
and alignment of 1
.
Implementations§
Source§impl NonZeroU32_ube
impl NonZeroU32_ube
Sourcepub const fn new(value: u32) -> Option<Self>
pub const fn new(value: u32) -> Option<Self>
Creates a non-zero if the given value is not zero.
Sourcepub const unsafe fn new_unchecked(value: u32) -> Self
pub const unsafe fn new_unchecked(value: u32) -> Self
Creates a non-zero without checking whether it is non-zero. This results in undefined behavior if the value is zero.
§Safety
The value must not be zero.
Sourcepub const fn from_native(value: NonZeroU32) -> Self
pub const fn from_native(value: NonZeroU32) -> Self
Returns a NonZeroU32_ube
containing value
.
Sourcepub const fn to_native(self) -> NonZeroU32
pub const fn to_native(self) -> NonZeroU32
Returns a NonZeroU32
with the same value as self
.
Trait Implementations§
Source§impl Binary for NonZeroU32_ube
impl Binary for NonZeroU32_ube
Source§impl BitOr<&NonZeroU32_ube> for &NonZeroU32_ube
impl BitOr<&NonZeroU32_ube> for &NonZeroU32_ube
Source§impl BitOr<&NonZeroU32_ube> for NonZeroU32
impl BitOr<&NonZeroU32_ube> for NonZeroU32
Source§impl BitOr<&NonZeroU32_ube> for NonZeroU32_ube
impl BitOr<&NonZeroU32_ube> for NonZeroU32_ube
Source§impl BitOr<NonZeroU32_ube> for &NonZeroU32_ube
impl BitOr<NonZeroU32_ube> for &NonZeroU32_ube
Source§impl BitOr<NonZeroU32_ube> for NonZeroU32
impl BitOr<NonZeroU32_ube> for NonZeroU32
Source§impl BitOr for NonZeroU32_ube
impl BitOr for NonZeroU32_ube
Source§impl BitOrAssign<NonZero<u32>> for NonZeroU32_ube
impl BitOrAssign<NonZero<u32>> for NonZeroU32_ube
Source§fn bitor_assign(&mut self, other: NonZeroU32)
fn bitor_assign(&mut self, other: NonZeroU32)
Performs the
|=
operation. Read moreSource§impl BitOrAssign for NonZeroU32_ube
impl BitOrAssign for NonZeroU32_ube
Source§fn bitor_assign(&mut self, other: NonZeroU32_ube)
fn bitor_assign(&mut self, other: NonZeroU32_ube)
Performs the
|=
operation. Read moreSource§impl Clone for NonZeroU32_ube
impl Clone for NonZeroU32_ube
Source§impl Debug for NonZeroU32_ube
impl Debug for NonZeroU32_ube
Source§impl Display for NonZeroU32_ube
impl Display for NonZeroU32_ube
Source§impl<'a> From<&'a NonZero<u32>> for NonZeroU32_ube
impl<'a> From<&'a NonZero<u32>> for NonZeroU32_ube
Source§fn from(value: &'a NonZeroU32) -> Self
fn from(value: &'a NonZeroU32) -> Self
Converts to this type from the input type.
Source§impl<'a> From<&'a NonZeroU32_ube> for NonZeroU32
impl<'a> From<&'a NonZeroU32_ube> for NonZeroU32
Source§fn from(value: &'a NonZeroU32_ube) -> Self
fn from(value: &'a NonZeroU32_ube) -> Self
Converts to this type from the input type.
Source§impl From<NonZero<u32>> for NonZeroU32_ube
impl From<NonZero<u32>> for NonZeroU32_ube
Source§fn from(value: NonZeroU32) -> Self
fn from(value: NonZeroU32) -> Self
Converts to this type from the input type.
Source§impl From<NonZeroU32_ube> for NonZeroU32
impl From<NonZeroU32_ube> for NonZeroU32
Source§fn from(value: NonZeroU32_ube) -> Self
fn from(value: NonZeroU32_ube) -> Self
Converts to this type from the input type.
Source§impl Hash for NonZeroU32_ube
impl Hash for NonZeroU32_ube
Source§impl LowerHex for NonZeroU32_ube
impl LowerHex for NonZeroU32_ube
Source§impl Octal for NonZeroU32_ube
impl Octal for NonZeroU32_ube
Source§impl Ord for NonZeroU32_ube
impl Ord for NonZeroU32_ube
Source§impl PartialEq<NonZeroU32_ube> for NonZeroU32
impl PartialEq<NonZeroU32_ube> for NonZeroU32
Source§impl PartialEq for NonZeroU32_ube
impl PartialEq for NonZeroU32_ube
Source§impl PartialOrd<NonZero<u32>> for NonZeroU32_ube
impl PartialOrd<NonZero<u32>> for NonZeroU32_ube
Source§impl PartialOrd for NonZeroU32_ube
impl PartialOrd for NonZeroU32_ube
Source§impl UpperHex for NonZeroU32_ube
impl UpperHex for NonZeroU32_ube
impl Copy for NonZeroU32_ube
impl Eq for NonZeroU32_ube
Auto Trait Implementations§
impl Freeze for NonZeroU32_ube
impl RefUnwindSafe for NonZeroU32_ube
impl Send for NonZeroU32_ube
impl Sync for NonZeroU32_ube
impl Unpin for NonZeroU32_ube
impl UnwindSafe for NonZeroU32_ube
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)