On Tuesday, 14 February 2012 at 15:39:37 UTC, Joshua Reusch wrote:
Hello,

why does this assertion fail:

> assert(float.nan == float.nan);

there is the std.math.isNaN function which works correctly, but why can I not just use the comparison ?

Thanks, Joshua

Use `float.nan is float.nan`; all other expressions with NaNs in them will be false (or result in NaN).

Reply via email to