FromOverFlow

Trait FromOverFlow 

Source
pub trait FromOverFlow<T>: Sized {
    // Required method
    fn from_overflow(_: T) -> Self;
}
Expand description

Like from, but will conceptually overflow if the value is too big this is useful from going from higher ranges to lower ranges

Required Methods§

Source

fn from_overflow(_: T) -> Self

Convert with overflowing.

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.

Implementors§