Ignore:
Timestamp:
Oct 7, 2011, 11:37:45 PM (14 years ago)
Author:
[email protected]
Message:

Add static version of JSCell::deleteProperty
https://bugs.webkit.org/show_bug.cgi?id=69659

Reviewed by Geoffrey Garen.

Source/JavaScriptCore:

Added static version of both versions of put to all classes that
override them and changed the virtual versions to call the static
versions. This is the first step in de-virtualizing JSCell::deleteProperty.

  • API/JSCallbackObject.h:
  • API/JSCallbackObjectFunctions.h:

(JSC::::deleteProperty):

  • debugger/DebuggerActivation.cpp:

(JSC::DebuggerActivation::deleteProperty):

  • debugger/DebuggerActivation.h:
  • runtime/Arguments.cpp:

(JSC::Arguments::deleteProperty):

  • runtime/Arguments.h:
  • runtime/JSActivation.cpp:

(JSC::JSActivation::deleteProperty):

  • runtime/JSActivation.h:
  • runtime/JSArray.cpp:

(JSC::JSArray::deleteProperty):

  • runtime/JSArray.h:
  • runtime/JSCell.cpp:

(JSC::JSCell::deleteProperty):

  • runtime/JSCell.h:
  • runtime/JSFunction.cpp:

(JSC::JSFunction::deleteProperty):

  • runtime/JSFunction.h:
  • runtime/JSNotAnObject.cpp:

(JSC::JSNotAnObject::deleteProperty):

  • runtime/JSNotAnObject.h:
  • runtime/JSObject.cpp:

(JSC::JSObject::deleteProperty):

  • runtime/JSObject.h:
  • runtime/JSVariableObject.cpp:

(JSC::JSVariableObject::deleteProperty):

  • runtime/JSVariableObject.h:
  • runtime/RegExpMatchesArray.h:

(JSC::RegExpMatchesArray::deleteProperty):

  • runtime/StrictEvalActivation.cpp:

(JSC::StrictEvalActivation::deleteProperty):

  • runtime/StrictEvalActivation.h:
  • runtime/StringObject.cpp:

(JSC::StringObject::deleteProperty):

  • runtime/StringObject.h:

Source/WebCore:

No new tests.

Added static version of both versions of put to all classes that
override them and changed the virtual versions to call the static
versions. This is the first step in de-virtualizing JSCell::deleteProperty.

  • bridge/objc/objc_runtime.h:
  • bridge/objc/objc_runtime.mm:

(JSC::Bindings::ObjcFallbackObjectImp::deleteProperty):

  • bridge/runtime_array.cpp:

(JSC::RuntimeArray::deleteProperty):

  • bridge/runtime_array.h:
  • bridge/runtime_object.cpp:

(JSC::Bindings::RuntimeObject::deleteProperty):

  • bridge/runtime_object.h:
File:
1 edited

Legend:

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

    r96996 r97002  
    330330bool JSFunction::deleteProperty(ExecState* exec, const Identifier& propertyName)
    331331{
    332     if (isHostFunction())
    333         return Base::deleteProperty(exec, propertyName);
     332    return deleteProperty(this, exec, propertyName);
     333}
     334
     335bool JSFunction::deleteProperty(JSCell* cell, ExecState* exec, const Identifier& propertyName)
     336{
     337    JSFunction* thisObject = static_cast<JSFunction*>(cell);
     338    if (thisObject->isHostFunction())
     339        return Base::deleteProperty(thisObject, exec, propertyName);
    334340    if (propertyName == exec->propertyNames().arguments || propertyName == exec->propertyNames().length)
    335341        return false;
    336     return Base::deleteProperty(exec, propertyName);
     342    return Base::deleteProperty(thisObject, exec, propertyName);
    337343}
    338344
Note: See TracChangeset for help on using the changeset viewer.