pub trait BitsFitIn<T> {
// Required method
fn fit(self) -> T;
}
Expand description
A conversion type for fitting the bits of one type into the bits of another type
This differs from Into
because the value may not be semantically the
same, this trait just asserts that the conversion can be done injectively.
The default implementation for our numeric types is to zero-extend the bits to fit the target size.