Trait Saturatingable

Source
pub trait Saturatingable: Sized
where Saturating<Self>: Copy + Bounded + Zero + One + Eq + Ord + Default + FromStr + Display + Add<Output = Saturating<Self>> + Sub<Output = Saturating<Self>> + Mul<Output = Saturating<Self>> + Div<Output = Saturating<Self>> + Rem<Output = Saturating<Self>> + BitAnd<Output = Saturating<Self>> + BitOr<Output = Saturating<Self>> + BitXor<Output = Saturating<Self>> + Shl<u32, Output = Saturating<Self>> + Shr<u32, Output = Saturating<Self>> + AddAssign + SubAssign + MulAssign + DivAssign + RemAssign + BitAndAssign + BitOrAssign + BitXorAssign + ShlAssign<u32> + ShrAssign<u32> + Not<Output = Saturating<Self>> + Add<Self, Output = Saturating<Self>> + Sub<Self, Output = Saturating<Self>> + Mul<Self, Output = Saturating<Self>> + Div<Self, Output = Saturating<Self>> + Rem<Self, Output = Saturating<Self>> + BitAnd<Self, Output = Saturating<Self>> + BitOr<Self, Output = Saturating<Self>> + BitXor<Self, Output = Saturating<Self>> + AddAssign<Self> + SubAssign<Self> + MulAssign<Self> + DivAssign<Self> + RemAssign<Self> + BitAndAssign<Self> + BitOrAssign<Self> + BitXorAssign<Self>,
{ // Provided methods fn to_saturating(self) -> Saturating<Self> { ... } fn from_saturating(s: Saturating<Self>) -> Self { ... } }

Provided Methods§

Source

fn to_saturating(self) -> Saturating<Self>

Source

fn from_saturating(s: Saturating<Self>) -> Self

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementations on Foreign Types§

Source§

impl Saturatingable for i8

Source§

impl Saturatingable for i16

Source§

impl Saturatingable for i32

Source§

impl Saturatingable for i64

Source§

impl Saturatingable for i128

Source§

impl Saturatingable for isize

Source§

impl Saturatingable for u8

Source§

impl Saturatingable for u16

Source§

impl Saturatingable for u32

Source§

impl Saturatingable for u64

Source§

impl Saturatingable for u128

Source§

impl Saturatingable for usize

Implementors§