Changeset 34961 in webkit for trunk/JavaScriptCore
- Timestamp:
- Jul 2, 2008, 5:04:19 PM (17 years ago)
- Location:
- trunk/JavaScriptCore
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/JavaScriptCore/ChangeLog
r34960 r34961 1 2008-07-02 Cameron Zwarich <[email protected]> 2 3 Reviewed by Darin. 4 5 Bug 19776: Number.toExponential() is incorrect for numbers between 0.1 and 1 6 <https://bugs.webkit.org/show_bug.cgi?id=19776> 7 8 Perform the sign check for the exponent on the actual exponent value, 9 which is 1 less than the value of decimalPoint, instead of on the value 10 of decimalPoint itself. 11 12 * kjs/NumberPrototype.cpp: 13 (KJS::exponentialPartToString): 14 1 15 2008-07-02 Kevin McCullough <[email protected]> 2 16 -
trunk/JavaScriptCore/kjs/NumberPrototype.cpp
r34904 r34961 290 290 { 291 291 buf[i++] = 'e'; 292 buf[i++] = (decimalPoint >= 0) ? '+' : '-';293 292 // decimalPoint can't be more than 3 digits decimal given the 294 293 // nature of float representation 295 294 int exponential = decimalPoint - 1; 295 buf[i++] = (exponential >= 0) ? '+' : '-'; 296 296 if (exponential < 0) 297 297 exponential *= -1;
Note:
See TracChangeset
for help on using the changeset viewer.