News for hackers. Stuff that matters.
Re:The Secret Life of NaN by jcranmer on Monday April 27, 2026 @10:47PM (#47929972)
> every operation that has a NaN as an operand produces a NaN as a result.

That's not true. The minimum/maximum functions (fmin and fminimum_num variants, but not the fminimum one) treat NaN inputs as not-present, so return the non-NaN value if there is one. Similarly, hypot also treats NaN inputs as not-present. pow and compoundn will ignore NaN exponents if the base is 1.

Re:The Secret Life of NaN by WalterBright on Monday April 27, 2026 @11:07PM (#47930066)
Yes, there are some functions where if one operand has no effect on the result, a NaN value will also have no effect.