On 01/14/2013 08:34 AM, Mischa Baars wrote: > When running the example attached, you can see the compiler fails to > recognize not-a-number's properly. > > Anyone who would like to have a look?
Comparing NaN with anything always returns false. Even when comparing
with NaN.
You want:
if (x != x)
{
printf("found a not-a-number\n");
}
Andrew.
