pub trait FromUsize: Sized {
    fn from_usize(n: usize) -> Option<Self>;
}
Expand description

Specifies how to obtain an instance of this numeric type equal to the usize primitive. If the number is too large to represent in this type, None should be returned instead.

The boilerplate implementations for primitives is performed with a macro. If a primitive type is missing from this list, please open an issue to add it in.

Required methods

Implementations on Foreign Types

Implementors