#[non_exhaustive]pub enum CalcError {
Dice(Evaled<'static>, Error),
Overflow(Evaled<'static>),
Division(Evaled<'static>),
}
Expand description
Error that can occur during Evaled::calc()
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Dice(Evaled<'static>, Error)
Dice-related error (likely during totalling)
Overflow(Evaled<'static>)
Integer overflow (likely during calculation of a sum or product)
Division(Evaled<'static>)
Division-related error (likely division by zero)
Trait Implementations§
source§impl Error for CalcError
impl Error for CalcError
source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
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()
Auto Trait Implementations§
impl RefUnwindSafe for CalcError
impl Send for CalcError
impl Sync for CalcError
impl Unpin for CalcError
impl UnwindSafe for CalcError
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