Trait overflower_support::MulSaturate [] [src]

pub trait MulSaturate<RHS = Self> {
    type Output;
    fn mul_saturate(self, rhs: RHS) -> Self::Output;
}

Multiply two values, saturating on overflow

This trait does the same as std::ops::Mul for most values. it is specialized for integer types to saturate on over- or underflow.

Associated Types

The result type of the multiplication

Required Methods

multiply two values, saturate on overflow

Implementors