[][src]Trait arithmetic_eval::arith::CheckedArithmeticKind

pub trait CheckedArithmeticKind<T> {
    pub fn checked_neg(value: T) -> Option<T>;
}

Helper trait for CheckedArithmetic describing how number negation should be implemented.

Required methods

pub fn checked_neg(value: T) -> Option<T>[src]

Negates the provided value, or returns None if the value cannot be negated.

Loading content...

Implementors

impl<T: CheckedNeg> CheckedArithmeticKind<T> for Checked[src]

impl<T: Signed> CheckedArithmeticKind<T> for Unchecked[src]

impl<T: Unsigned + Zero> CheckedArithmeticKind<T> for NegateOnlyZero[src]

Loading content...