wasmtime-internal-core 47.0.3

INTERNAL: Wasmtime's core utilities and helpers with minimal dependencies
Documentation
1
2
3
4
5
6
7
8
9
10
11
//! Explicit methods to clearly indicate that truncation is desired when used.

/// Explicitly truncate an `i32` to an `i16`.
pub fn truncate_i32_to_i16(a: i32) -> i16 {
    a as i16
}

/// Explicitly truncate an `i32` to an `i8`.
pub fn truncate_i32_to_i8(a: i32) -> i8 {
    a as i8
}