pub enum ArrayFromTupleError<T> {
NotEnoughElements {
expected_len: usize,
actual_len: usize,
},
ElementFromObject {
element_idx: usize,
error: T,
},
}
Expand description
The error type returned when trying to convert an Array
into a tuple.
Variants§
NotEnoughElements
Not enough elements in the array.
ElementFromObject
The tuple element at the given index couldn’t be converted into the requested type.
Trait Implementations§
Source§impl<T: Debug> Debug for ArrayFromTupleError<T>
impl<T: Debug> Debug for ArrayFromTupleError<T>
Source§impl<T> Display for ArrayFromTupleError<T>where
T: Debug,
impl<T> Display for ArrayFromTupleError<T>where
T: Debug,
Source§impl<T> Error for ArrayFromTupleError<T>
impl<T> Error for ArrayFromTupleError<T>
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<T: PartialEq> PartialEq for ArrayFromTupleError<T>
impl<T: PartialEq> PartialEq for ArrayFromTupleError<T>
impl<T: Eq> Eq for ArrayFromTupleError<T>
impl<T> StructuralPartialEq for ArrayFromTupleError<T>
Auto Trait Implementations§
impl<T> Freeze for ArrayFromTupleError<T>where
T: Freeze,
impl<T> RefUnwindSafe for ArrayFromTupleError<T>where
T: RefUnwindSafe,
impl<T> Send for ArrayFromTupleError<T>where
T: Send,
impl<T> Sync for ArrayFromTupleError<T>where
T: Sync,
impl<T> Unpin for ArrayFromTupleError<T>where
T: Unpin,
impl<T> UnwindSafe for ArrayFromTupleError<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> IntoResult<T> for T
impl<T> IntoResult<T> for T
Source§type Error = Infallible
type Error = Infallible
The error type in the returned
Result
.Source§fn into_result(self) -> Result<T, <T as IntoResult<T>>::Error>
fn into_result(self) -> Result<T, <T as IntoResult<T>>::Error>
Converts the value into a
Result
.