Skip to main content

CANONICAL_NAN_BITS

Constant CANONICAL_NAN_BITS 

Source
pub const CANONICAL_NAN_BITS: u64 = 0x7FF8_0000_0000_0000;
Expand description

The bits every NaN is written as: the canonical quiet NaN. A NaN’s sign and payload differ by host (x86 arithmetic makes 0xFFF8…, other hosts and WASM differ), and the wire is the one place a program can read a float’s bits, so every encoder writes a NaN as this and nothing else.