Trait sp_arithmetic::traits::UniqueSaturatedFrom[][src]

pub trait UniqueSaturatedFrom<T: Sized>: Sized {
    fn unique_saturated_from(t: T) -> Self;

Just like From except that if the source value is too big to fit into the destination type then it’ll saturate the destination.

Required methods

fn unique_saturated_from(t: T) -> Self[src]

Convert from a value of T into an equivalent instance of Self.

Loading content...


impl<T: Sized, S: TryFrom<T> + Bounded + Sized> UniqueSaturatedFrom<T> for S[src]

Loading content...