#[repr(transparent)]pub struct WriteableAsTryWriteableInfallible<T>(pub T);
Expand description
A wrapper around Writeable
that implements TryWriteable
with TryWriteable::Error
set to Infallible
.
Tuple Fields§
§0: T
Trait Implementations§
source§impl<T: Clone> Clone for WriteableAsTryWriteableInfallible<T>
impl<T: Clone> Clone for WriteableAsTryWriteableInfallible<T>
source§fn clone(&self) -> WriteableAsTryWriteableInfallible<T>
fn clone(&self) -> WriteableAsTryWriteableInfallible<T>
Returns a copy 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<T: Debug> Debug for WriteableAsTryWriteableInfallible<T>
impl<T: Debug> Debug for WriteableAsTryWriteableInfallible<T>
source§impl<T: Hash> Hash for WriteableAsTryWriteableInfallible<T>
impl<T: Hash> Hash for WriteableAsTryWriteableInfallible<T>
source§impl<T: Ord> Ord for WriteableAsTryWriteableInfallible<T>
impl<T: Ord> Ord for WriteableAsTryWriteableInfallible<T>
source§fn cmp(&self, other: &WriteableAsTryWriteableInfallible<T>) -> Ordering
fn cmp(&self, other: &WriteableAsTryWriteableInfallible<T>) -> 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<T: PartialEq> PartialEq for WriteableAsTryWriteableInfallible<T>
impl<T: PartialEq> PartialEq for WriteableAsTryWriteableInfallible<T>
source§fn eq(&self, other: &WriteableAsTryWriteableInfallible<T>) -> bool
fn eq(&self, other: &WriteableAsTryWriteableInfallible<T>) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl<T: PartialOrd> PartialOrd for WriteableAsTryWriteableInfallible<T>
impl<T: PartialOrd> PartialOrd for WriteableAsTryWriteableInfallible<T>
source§fn partial_cmp(
&self,
other: &WriteableAsTryWriteableInfallible<T>,
) -> Option<Ordering>
fn partial_cmp( &self, other: &WriteableAsTryWriteableInfallible<T>, ) -> Option<Ordering>
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 moresource§impl<T> TryWriteable for WriteableAsTryWriteableInfallible<T>where
T: Writeable,
impl<T> TryWriteable for WriteableAsTryWriteableInfallible<T>where
T: Writeable,
type Error = Infallible
source§fn try_write_to<W: Write + ?Sized>(
&self,
sink: &mut W,
) -> Result<Result<(), Infallible>, Error>
fn try_write_to<W: Write + ?Sized>( &self, sink: &mut W, ) -> Result<Result<(), Infallible>, Error>
Writes the content of this writeable to a sink. Read more
source§fn try_write_to_parts<S: PartsWrite + ?Sized>(
&self,
sink: &mut S,
) -> Result<Result<(), Infallible>, Error>
fn try_write_to_parts<S: PartsWrite + ?Sized>( &self, sink: &mut S, ) -> Result<Result<(), Infallible>, Error>
Writes the content of this writeable to a sink with parts (annotations). Read more
source§fn writeable_length_hint(&self) -> LengthHint
fn writeable_length_hint(&self) -> LengthHint
Returns a hint for the number of UTF-8 bytes that will be written to the sink. Read more
source§fn try_write_to_string(
&self,
) -> Result<Cow<'_, str>, (Infallible, Cow<'_, str>)>
fn try_write_to_string( &self, ) -> Result<Cow<'_, str>, (Infallible, Cow<'_, str>)>
Writes the content of this writeable to a string. Read more
impl<T: Eq> Eq for WriteableAsTryWriteableInfallible<T>
impl<T> StructuralPartialEq for WriteableAsTryWriteableInfallible<T>
Auto Trait Implementations§
impl<T> Freeze for WriteableAsTryWriteableInfallible<T>where
T: Freeze,
impl<T> RefUnwindSafe for WriteableAsTryWriteableInfallible<T>where
T: RefUnwindSafe,
impl<T> Send for WriteableAsTryWriteableInfallible<T>where
T: Send,
impl<T> Sync for WriteableAsTryWriteableInfallible<T>where
T: Sync,
impl<T> Unpin for WriteableAsTryWriteableInfallible<T>where
T: Unpin,
impl<T> UnwindSafe for WriteableAsTryWriteableInfallible<T>where
T: UnwindSafe,
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§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)