pub struct NonZeroChar(/* private fields */);Expand description
A char that is guaranteed to be nonzero
Implementations§
Source§impl NonZeroChar
impl NonZeroChar
Sourcepub const unsafe fn new_unchecked(ch: char) -> Self
pub const unsafe fn new_unchecked(ch: char) -> Self
Trait Implementations§
Source§impl Clone for NonZeroChar
impl Clone for NonZeroChar
Source§fn clone(&self) -> NonZeroChar
fn clone(&self) -> NonZeroChar
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for NonZeroChar
impl Debug for NonZeroChar
Source§impl Display for NonZeroChar
impl Display for NonZeroChar
Source§impl From<NonZeroChar> for char
impl From<NonZeroChar> for char
Source§fn from(value: NonZeroChar) -> Self
fn from(value: NonZeroChar) -> Self
Converts to this type from the input type.
Source§impl Hash for NonZeroChar
impl Hash for NonZeroChar
Source§impl Ord for NonZeroChar
impl Ord for NonZeroChar
Source§fn cmp(&self, other: &NonZeroChar) -> Ordering
fn cmp(&self, other: &NonZeroChar) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialEq for NonZeroChar
impl PartialEq for NonZeroChar
Source§impl PartialOrd for NonZeroChar
impl PartialOrd for NonZeroChar
Source§impl TryFrom<char> for NonZeroChar
impl TryFrom<char> for NonZeroChar
impl Copy for NonZeroChar
impl Eq for NonZeroChar
impl StructuralPartialEq for NonZeroChar
Auto Trait Implementations§
impl Freeze for NonZeroChar
impl RefUnwindSafe for NonZeroChar
impl Send for NonZeroChar
impl Sync for NonZeroChar
impl Unpin for NonZeroChar
impl UnwindSafe for NonZeroChar
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