pub enum MBarError {
BuilderError(String),
UnhandledPythonException {
source: PyErr,
},
ArrayLengthMismatch(usize, usize),
PythonNotUsize {
source: TryFromIntError,
},
}
Expand description
Enum for errors in this crate
Variants§
BuilderError(String)
Error returned when MBarBuilder.build() was called improperly
UnhandledPythonException
Error returned when a python exception is not handled
ArrayLengthMismatch(usize, usize)
Error returned when an array is the wrong length
PythonNotUsize
Error returned when an integer from Python fails to cast to usize
Fields
§
source: TryFromIntError
Implementations§
Trait Implementations§
Source§impl Error for MBarError
impl Error for MBarError
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<TryFromIntError> for MBarError
impl From<TryFromIntError> for MBarError
Source§fn from(source: TryFromIntError) -> Self
fn from(source: TryFromIntError) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl !Freeze for MBarError
impl !RefUnwindSafe for MBarError
impl Send for MBarError
impl Sync for MBarError
impl Unpin for MBarError
impl !UnwindSafe for MBarError
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