Changeset 27484 in webkit for trunk/JavaScriptCore/kjs/nodes.cpp


Ignore:
Timestamp:
Nov 6, 2007, 11:49:39 AM (18 years ago)
Author:
oliver
Message:

Fix previous patch to use a 3 bit shift, a 16 bit shift causes a regression in sunspider.

RS=Darin

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/JavaScriptCore/kjs/nodes.cpp

    r27483 r27484  
    17081708    JSType t1 = v1->type();
    17091709    JSType t2 = v2->type();
    1710     const unsigned bothTypes = (t1 << 16) | t2;
     1710    const unsigned bothTypes = (t1 << 3) | t2;
    17111711   
    1712     if (bothTypes == ((NumberType << 16) | NumberType))
     1712    if (bothTypes == ((NumberType << 3) | NumberType))
    17131713        return jsNumber(v1->toNumber(exec) + v2->toNumber(exec));
    1714     else if (bothTypes == ((StringType << 16) | StringType)) {
     1714    else if (bothTypes == ((StringType << 3) | StringType)) {
    17151715        UString value = static_cast<StringImp*>(v1)->value() + static_cast<StringImp*>(v2)->value();
    17161716        if (value.isNull())
Note: See TracChangeset for help on using the changeset viewer.