Ignore:
Timestamp:
Feb 21, 2011, 12:46:50 PM (14 years ago)
Author:
[email protected]
Message:

Ruber stamped by Sam Weinig

Bug 54899 - Math.LOG10E should be 0.4342944819032518
This value is quoted in section 15.8.1.5 of the spec.

Source/JavaScriptCore:

  • runtime/MathObject.cpp:

(JSC::MathObject::MathObject):

LayoutTests:

  • fast/js/kde/math-expected.txt:
  • fast/js/kde/script-tests/math.js:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/JavaScriptCore/runtime/MathObject.cpp

    r79240 r79246  
    9696    putDirectWithoutTransition(exec->globalData(), Identifier(exec, "LN10"), jsNumber(log(10.0)), DontDelete | DontEnum | ReadOnly);
    9797    putDirectWithoutTransition(exec->globalData(), Identifier(exec, "LOG2E"), jsNumber(1.0 / log(2.0)), DontDelete | DontEnum | ReadOnly);
    98     putDirectWithoutTransition(exec->globalData(), Identifier(exec, "LOG10E"), jsNumber(1.0 / log(10.0)), DontDelete | DontEnum | ReadOnly);
     98    putDirectWithoutTransition(exec->globalData(), Identifier(exec, "LOG10E"), jsNumber(0.4342944819032518), DontDelete | DontEnum | ReadOnly); // See ECMA-262 15.8.1.5
    9999    putDirectWithoutTransition(exec->globalData(), Identifier(exec, "PI"), jsNumber(piDouble), DontDelete | DontEnum | ReadOnly);
    100100    putDirectWithoutTransition(exec->globalData(), Identifier(exec, "SQRT1_2"), jsNumber(sqrt(0.5)), DontDelete | DontEnum | ReadOnly);
Note: See TracChangeset for help on using the changeset viewer.