pub enum TryFromError {
Generic(&'static str),
Unimplemented,
UnsupportedSourceShape {
src_shape: &'static Shape,
expected: &'static [&'static Shape],
},
Unsized,
}
Expand description
Error type for TryFrom conversion failures
Variants§
Generic(&'static str)
Generic conversion error
Unimplemented
The target shape doesn’t implement conversion from any source shape (no try_from in vtable)
UnsupportedSourceShape
The target shape has a conversion implementation, but it doesn’t support converting from this specific source shape
Fields
Unsized
!Sized
type
Trait Implementations§
Source§impl Clone for TryFromError
impl Clone for TryFromError
Source§fn clone(&self) -> TryFromError
fn clone(&self) -> TryFromError
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 TryFromError
impl Debug for TryFromError
Source§impl Display for TryFromError
impl Display for TryFromError
Source§impl Error for TryFromError
impl Error for TryFromError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()
Source§impl From<UnsizedError> for TryFromError
impl From<UnsizedError> for TryFromError
Source§fn from(_value: UnsizedError) -> Self
fn from(_value: UnsizedError) -> Self
Converts to this type from the input type.
Source§impl PartialEq for TryFromError
impl PartialEq for TryFromError
impl StructuralPartialEq for TryFromError
Auto Trait Implementations§
impl Freeze for TryFromError
impl RefUnwindSafe for TryFromError
impl Send for TryFromError
impl Sync for TryFromError
impl Unpin for TryFromError
impl UnwindSafe for TryFromError
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