Struct sp_inherents::MakeFatalError
source · [−]pub struct MakeFatalError<E: Encode>(_);
Expand description
Auxiliary to make any given error resolve to is_fatal_error() == true
.
Trait Implementations
sourceimpl<E: Encode> Encode for MakeFatalError<E> where
E: Encode,
E: Encode,
impl<E: Encode> Encode for MakeFatalError<E> where
E: Encode,
E: Encode,
sourcefn encode_to<__CodecOutputEdqy: Output + ?Sized>(
&self,
__codec_dest_edqy: &mut __CodecOutputEdqy
)
fn encode_to<__CodecOutputEdqy: Output + ?Sized>(
&self,
__codec_dest_edqy: &mut __CodecOutputEdqy
)
Convert self to a slice and append it to the destination.
sourcefn using_encoded<R, F: FnOnce(&[u8]) -> R>(&self, f: F) -> R
fn using_encoded<R, F: FnOnce(&[u8]) -> R>(&self, f: F) -> R
Convert self to a slice and then invoke the given closure with it.
sourcefn size_hint(&self) -> usize
fn size_hint(&self) -> usize
If possible give a hint of expected size of the encoding. Read more
sourcefn encoded_size(&self) -> usize
fn encoded_size(&self) -> usize
Calculates the encoded size. Read more
sourceimpl<E: Encode> From<E> for MakeFatalError<E>
impl<E: Encode> From<E> for MakeFatalError<E>
sourceimpl<E: Encode> IsFatalError for MakeFatalError<E>
impl<E: Encode> IsFatalError for MakeFatalError<E>
sourcefn is_fatal_error(&self) -> bool
fn is_fatal_error(&self) -> bool
Is this a fatal error?
impl<E: Encode> EncodeLike<MakeFatalError<E>> for MakeFatalError<E> where
E: Encode,
E: Encode,
Auto Trait Implementations
impl<E> RefUnwindSafe for MakeFatalError<E> where
E: RefUnwindSafe,
impl<E> Send for MakeFatalError<E> where
E: Send,
impl<E> Sync for MakeFatalError<E> where
E: Sync,
impl<E> Unpin for MakeFatalError<E> where
E: Unpin,
impl<E> UnwindSafe for MakeFatalError<E> where
E: UnwindSafe,
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more