method f32.isNaN
Whether the value is not a number (the result of 0.0 / 0.0).
Example:
fn main() io {
let zero: f32 = 0.0
let nan = zero / zero
print("{nan.isNaN()} {(1.5 as f32).isNaN()}")
}Output
true false
pub(api) fn isNaN() -> boolComplexity. O(1).
Since. 1.0.0-beta
Returns
bool
Effects
none declared (pure unless the body says otherwise)
Defined in: std/core/numbers.oxl:4394