Changeset 91938 in webkit for trunk/Source/JavaScriptCore/runtime/JSGlobalObjectFunctions.cpp
- Timestamp:
- Jul 28, 2011, 10:32:40 AM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/JavaScriptCore/runtime/JSGlobalObjectFunctions.cpp
r89219 r91938 461 461 { 462 462 JSValue value = exec->argument(0); 463 464 // Optimized case: If the argument is a positive number in the integer 465 // range, and the exponent is 10, then parseInt is equivalent to floor. 466 double n; 467 if (value.getNumber(n) && n >= 0 && n < INT_MAX && exec->argument(1).isUndefined()) 468 return JSValue::encode(jsNumber(static_cast<int>(n))); 469 463 470 int32_t radix = exec->argument(1).toInt32(exec); 464 471
Note:
See TracChangeset
for help on using the changeset viewer.