Commit f8fa72ec authored by mjs's avatar mjs

Reviewed by Darin.

        
        - fixed "charAt layout test fails on intel macs; some NaNs are printed as -NaN"
        http://bugzilla.opendarwin.org/show_bug.cgi?id=7745

        * kjs/ustring.cpp:
        (KJS::UString::from): Use "NaN" for all NaN values, regardless of sign.



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@13365 268f45cc-cd09-0410-ab3c-d52691b4dbfc
parent dcce106f
2006-03-11 Maciej Stachowiak <mjs@apple.com>
Reviewed by Darin.
- fixed "charAt layout test fails on intel macs; some NaNs are printed as -NaN"
http://bugzilla.opendarwin.org/show_bug.cgi?id=7745
* kjs/ustring.cpp:
(KJS::UString::from): Use "NaN" for all NaN values, regardless of sign.
2006-03-16 Maciej Stachowiak <mjs@apple.com>
Reviewed by Darin.
......
......@@ -561,6 +561,10 @@ UString UString::from(long l)
UString UString::from(double d)
{
// avoid ever printing -NaN, in JS conceptually there is only one NaN value
if (isNaN(d))
return "NaN";
char buf[80];
int decimalPoint;
int sign;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment