#[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
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§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§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
)