wasmtime_environ::__core::intrinsics

Function three_way_compare

Source
pub const fn three_way_compare<T>(_lhs: T, _rhss: T) -> Ordering
where T: Copy,
🔬This is a nightly-only experimental API. (core_intrinsics)
Expand description

Does a three-way comparison between the two integer arguments.

This is included as an intrinsic as it’s useful to let it be one thing in MIR, rather than the multiple checks and switches that make its IR large and difficult to optimize.

The stabilized version of this intrinsic is Ord::cmp.