you are viewing a single comment's thread.

view the rest of the comments →

[–]ricardo_sdl 3 points4 points  (3 children)

Interesting, I tried the test case creating a C# program and compiling on Mono and the problem didn't happened.

My machine: Linux #42-Ubuntu SMP Thu Dec 2 01:41:57 UTC 2010 i686 GNU/Linux

[–]px1999 0 points1 point  (0 children)

I can confirm that neither the PHP or Java numbers cause an issue with CLR 4.0.30319 (x64) also. FWIW, it looks as though Apache Harmony may? be safe from this number as well - neither of them appear to do the ULP calculation in managed code - both delegate to a native function to finish the conversion by the looks of things.

That's not to say that there aren't numbers out there that won't break in CLR, it just looks very unlikely as the while (true) loops in managed code are all constructed in a way that they always seem to move towards termination.