Enum anyint::error::ParseIntError
source · [−]pub enum ParseIntError {
Empty,
InvalidDigit,
OutOfRange(OutOfRangeIntError),
Unknown,
}Expand description
Enum to store the various types of errors that can cause parsing an integer to fail.
Variants
Empty
cannot parse integer from empty string
InvalidDigit
invalid digit found in string
OutOfRange(OutOfRangeIntError)
Value {0} was too large or small to store in the target type.
Unknown
Unknown parsing error, this should never happen.
Trait Implementations
sourceimpl Clone for ParseIntError
impl Clone for ParseIntError
sourcefn clone(&self) -> ParseIntError
fn clone(&self) -> ParseIntError
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read more
sourceimpl Debug for ParseIntError
impl Debug for ParseIntError
sourceimpl From<IntErrorKind> for ParseIntError
impl From<IntErrorKind> for ParseIntError
sourcefn from(kind: IntErrorKind) -> Self
fn from(kind: IntErrorKind) -> Self
Converts to this type from the input type.
sourceimpl From<OutOfRangeIntError> for ParseIntError
impl From<OutOfRangeIntError> for ParseIntError
sourcefn from(err: OutOfRangeIntError) -> Self
fn from(err: OutOfRangeIntError) -> Self
Converts to this type from the input type.
sourceimpl Hash for ParseIntError
impl Hash for ParseIntError
sourceimpl Ord for ParseIntError
impl Ord for ParseIntError
sourceimpl PartialEq<ParseIntError> for ParseIntError
impl PartialEq<ParseIntError> for ParseIntError
sourcefn eq(&self, other: &ParseIntError) -> bool
fn eq(&self, other: &ParseIntError) -> bool
This method tests for self and other values to be equal, and is used
by ==. Read more
sourcefn ne(&self, other: &ParseIntError) -> bool
fn ne(&self, other: &ParseIntError) -> bool
This method tests for !=.
sourceimpl PartialOrd<ParseIntError> for ParseIntError
impl PartialOrd<ParseIntError> for ParseIntError
sourcefn partial_cmp(&self, other: &ParseIntError) -> Option<Ordering>
fn partial_cmp(&self, other: &ParseIntError) -> Option<Ordering>
This method returns an ordering between self and other values if one exists. Read more
1.0.0 · sourcefn lt(&self, other: &Rhs) -> bool
fn lt(&self, other: &Rhs) -> bool
This method tests less than (for self and other) and is used by the < operator. Read more
1.0.0 · sourcefn 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 more
impl Copy for ParseIntError
impl Eq for ParseIntError
impl StructuralEq for ParseIntError
impl StructuralPartialEq for ParseIntError
Auto Trait Implementations
impl RefUnwindSafe for ParseIntError
impl Send for ParseIntError
impl Sync for ParseIntError
impl Unpin for ParseIntError
impl UnwindSafe for ParseIntError
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T, U> LossyInto<U> for T where
U: LossyFrom<T>,
impl<T, U> LossyInto<U> for T where
U: LossyFrom<T>,
sourcefn into_lossy(self) -> U
fn into_lossy(self) -> U
Performs the conversion, possibly losing data in the process.
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
toowned_clone_into)Uses borrowed data to replace owned data, usually by cloning. Read more
sourceimpl<T, U> UncheckedInto<U> for T where
U: UncheckedFrom<T>,
impl<T, U> UncheckedInto<U> for T where
U: UncheckedFrom<T>,
sourceunsafe fn into_unchecked(self) -> U
unsafe fn into_unchecked(self) -> U
Performs the conversion without checking, possibly performing undefined behavior in the process.
sourceimpl<T, U> WrappingInto<U> for T where
U: WrappingFrom<T>,
impl<T, U> WrappingInto<U> for T where
U: WrappingFrom<T>,
sourcefn into_wrapping(self) -> U
fn into_wrapping(self) -> U
Performs the conversion, possibly wrapping around in the process.