Function constmuck::contiguous::from_i16 [−][src]
pub const fn from_i16<T>(
integer: i16,
bounds: IsContiguous<T, i16>
) -> Option<T>
Expand description
Converts ìnteger: i16
to T
if it’s between the minimum and maximum values for T
, otherwise returns None
.
Requires that T
implements Contiguous<Int = i16>
Examples
For examples, you can look
at the ones for from_u8
.