Expand description
Casting.
This modules provides utilities for casting between types.
#[no_std] compatible.
§64-bit invariant
This module is available on 32-bit arches although panics
will occur between lossy casts, e.g. u64_to_usize where
the input is larger than u32::MAX.
On 64-bit arches, all functions are lossless.
Functions§
- i32_
to_ isize - Cast
i32toisize. - i64_
to_ isize - Cast
i64toisize. - isize_
to_ i64 - Cast
isizetoi64. - u32_
to_ usize - Cast
u32tousize. - u64_
to_ usize - Cast
u64tousize. - usize_
to_ u64 - Cast
usizetou64.