Float16 module

float32_to_float16

procedureSource

Converts a float32 to the nearest half; the usual name for float_to_half_fast3.

Example↗
assert(cast(u16) float32_to_float16(-2.0) == 0xc000);
float32_to_float16 :: (_f: float32) -> Float16

Parameters

_f: float32

Returns

See also