pub enum ErrorKind {
TypeError,
NameError,
DivisionByZero,
OverflowError,
SyntaxError,
NotImplemented,
}
Expand description
The ErrorKind enum is used to sort errors into different types. This allows error handling code to exhibit different behavior based on the kind of error.
Variants§
Trait Implementations§
Source§impl Display for ErrorKind
Implements the Display
trait for ErrorKind
.
This allows ErrorKind
to be formatted as a string when using the write!
macro.
impl Display for ErrorKind
Implements the Display
trait for ErrorKind
.
This allows ErrorKind
to be formatted as a string when using the write!
macro.
impl StructuralPartialEq for ErrorKind
Auto Trait Implementations§
impl Freeze for ErrorKind
impl RefUnwindSafe for ErrorKind
impl Send for ErrorKind
impl Sync for ErrorKind
impl Unpin for ErrorKind
impl UnwindSafe for ErrorKind
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