Changeset 160204 in webkit


Ignore:
Timestamp:
Dec 5, 2013 5:19:42 PM (10 years ago)
Author:
commit-queue@webkit.org
Message:

Unreviewed, rolling out r160133.
http://trac.webkit.org/changeset/160133
https://bugs.webkit.org/show_bug.cgi?id=125325

broke bindings tests on all the bots (Requested by thorton on
#webkit).

Source/JavaScriptCore:

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

(JSC::::staticFunctionGetter):
(JSC::::callbackGetter):

  • jit/JITOperations.cpp:
  • runtime/JSActivation.cpp:

(JSC::JSActivation::argumentsGetter):

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

(JSC::JSFunction::argumentsGetter):
(JSC::JSFunction::callerGetter):
(JSC::JSFunction::lengthGetter):
(JSC::JSFunction::nameGetter):

  • runtime/JSFunction.h:
  • runtime/JSObject.h:

(JSC::PropertySlot::getValue):

  • runtime/NumberConstructor.cpp:

(JSC::numberConstructorNaNValue):
(JSC::numberConstructorNegInfinity):
(JSC::numberConstructorPosInfinity):
(JSC::numberConstructorMaxValue):
(JSC::numberConstructorMinValue):

  • runtime/PropertySlot.h:
  • runtime/RegExpConstructor.cpp:

(JSC::regExpConstructorDollar1):
(JSC::regExpConstructorDollar2):
(JSC::regExpConstructorDollar3):
(JSC::regExpConstructorDollar4):
(JSC::regExpConstructorDollar5):
(JSC::regExpConstructorDollar6):
(JSC::regExpConstructorDollar7):
(JSC::regExpConstructorDollar8):
(JSC::regExpConstructorDollar9):
(JSC::regExpConstructorInput):
(JSC::regExpConstructorMultiline):
(JSC::regExpConstructorLastMatch):
(JSC::regExpConstructorLastParen):
(JSC::regExpConstructorLeftContext):
(JSC::regExpConstructorRightContext):

  • runtime/RegExpObject.cpp:

(JSC::regExpObjectGlobal):
(JSC::regExpObjectIgnoreCase):
(JSC::regExpObjectMultiline):
(JSC::regExpObjectSource):

Source/WebCore:

  • bindings/js/JSCSSStyleDeclarationCustom.cpp:

(WebCore::cssPropertyGetterPixelOrPosPrefixCallback):
(WebCore::cssPropertyGetterCallback):

  • bindings/js/JSDOMBinding.cpp:

(WebCore::objectToStringFunctionGetter):

  • bindings/js/JSDOMBinding.h:
  • bindings/js/JSDOMMimeTypeArrayCustom.cpp:

(WebCore::JSDOMMimeTypeArray::nameGetter):

  • bindings/js/JSDOMPluginArrayCustom.cpp:

(WebCore::JSDOMPluginArray::nameGetter):

  • bindings/js/JSDOMPluginCustom.cpp:

(WebCore::JSDOMPlugin::nameGetter):

  • bindings/js/JSDOMStringMapCustom.cpp:

(WebCore::JSDOMStringMap::nameGetter):

  • bindings/js/JSDOMWindowCustom.cpp:

(WebCore::nonCachingStaticFunctionGetter):
(WebCore::childFrameGetter):
(WebCore::indexGetter):
(WebCore::namedItemGetter):

  • bindings/js/JSHTMLAllCollectionCustom.cpp:

(WebCore::JSHTMLAllCollection::nameGetter):

  • bindings/js/JSHTMLCollectionCustom.cpp:

(WebCore::JSHTMLCollection::nameGetter):

  • bindings/js/JSHTMLDocumentCustom.cpp:

(WebCore::JSHTMLDocument::nameGetter):

  • bindings/js/JSHTMLFormControlsCollectionCustom.cpp:

(WebCore::JSHTMLFormControlsCollection::nameGetter):

  • bindings/js/JSHTMLFormElementCustom.cpp:

(WebCore::JSHTMLFormElement::nameGetter):

  • bindings/js/JSHTMLFrameSetElementCustom.cpp:

(WebCore::JSHTMLFrameSetElement::nameGetter):

  • bindings/js/JSHistoryCustom.cpp:

(WebCore::nonCachingStaticBackFunctionGetter):
(WebCore::nonCachingStaticForwardFunctionGetter):
(WebCore::nonCachingStaticGoFunctionGetter):

  • bindings/js/JSJavaScriptCallFrameCustom.cpp:

(WebCore::JSJavaScriptCallFrame::scopeType):

  • bindings/js/JSLocationCustom.cpp:

(WebCore::nonCachingStaticReplaceFunctionGetter):
(WebCore::nonCachingStaticReloadFunctionGetter):
(WebCore::nonCachingStaticAssignFunctionGetter):

  • bindings/js/JSNamedNodeMapCustom.cpp:

(WebCore::JSNamedNodeMap::nameGetter):

  • bindings/js/JSNodeListCustom.cpp:

(WebCore::JSNodeList::nameGetter):

  • bindings/js/JSPluginElementFunctions.cpp:

(WebCore::pluginElementPropertyGetter):

  • bindings/js/JSPluginElementFunctions.h:
  • bindings/js/JSRTCStatsResponseCustom.cpp:

(WebCore::JSRTCStatsResponse::nameGetter):

  • bindings/js/JSStorageCustom.cpp:

(WebCore::JSStorage::nameGetter):

  • bindings/js/JSStyleSheetListCustom.cpp:

(WebCore::JSStyleSheetList::nameGetter):

  • bindings/scripts/CodeGeneratorJS.pm:

(GenerateHeader):
(GenerateImplementation):
(GenerateParametersCheck):

  • bridge/runtime_array.cpp:

(JSC::RuntimeArray::lengthGetter):
(JSC::RuntimeArray::indexGetter):

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

(JSC::RuntimeMethod::lengthGetter):

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

(JSC::Bindings::RuntimeObject::fallbackObjectGetter):
(JSC::Bindings::RuntimeObject::fieldGetter):
(JSC::Bindings::RuntimeObject::methodGetter):

  • bridge/runtime_object.h:

Source/WebKit2:

  • WebProcess/Plugins/Netscape/JSNPMethod.cpp:

(WebKit::callMethod):

  • WebProcess/Plugins/Netscape/JSNPObject.cpp:

(WebKit::callNPJSObject):
(WebKit::constructWithConstructor):
(WebKit::JSNPObject::propertyGetter):
(WebKit::JSNPObject::methodGetter):

  • WebProcess/Plugins/Netscape/JSNPObject.h:
  • WebProcess/Plugins/Netscape/NPRuntimeObjectMap.cpp:

(WebKit::NPRuntimeObjectMap::getOrCreateNPObject):
(WebKit::NPRuntimeObjectMap::finalize):

  • WebProcess/WebPage/WebFrame.cpp:

(WebKit::WebFrame::counterValue):

Location:
trunk/Source
Files:
51 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/JavaScriptCore/API/JSCallbackObject.h

    r160133 r160204  
    206206 
    207207    static JSCallbackObject* asCallbackObject(JSValue);
    208     static JSCallbackObject* asCallbackObject(EncodedJSValue);
    209208 
    210209    static EncodedJSValue JSC_HOST_CALL call(ExecState*);
     
    212211   
    213212    JSValue getStaticValue(ExecState*, PropertyName);
    214     static EncodedJSValue staticFunctionGetter(ExecState*, EncodedJSValue, EncodedJSValue, PropertyName);
    215     static EncodedJSValue callbackGetter(ExecState*, EncodedJSValue, EncodedJSValue, PropertyName);
     213    static JSValue staticFunctionGetter(ExecState*, JSValue, PropertyName);
     214    static JSValue callbackGetter(ExecState*, JSValue, PropertyName);
    216215
    217216    OwnPtr<JSCallbackObjectData> m_callbackObjectData;
  • trunk/Source/JavaScriptCore/API/JSCallbackObjectFunctions.h

    r160133 r160204  
    5151
    5252template <class Parent>
    53 inline JSCallbackObject<Parent>* JSCallbackObject<Parent>::asCallbackObject(EncodedJSValue value)
    54 {
    55     ASSERT(asObject(JSValue::decode(value))->inherits(info()));
    56     return jsCast<JSCallbackObject*>(asObject(JSValue::decode(value)));
    57 }
    58 
    59 template <class Parent>
    6053JSCallbackObject<Parent>::JSCallbackObject(ExecState* exec, Structure* structure, JSClassRef jsClass, void* data)
    6154    : Parent(exec->vm(), structure)
     
    592585
    593586template <class Parent>
    594 EncodedJSValue JSCallbackObject<Parent>::staticFunctionGetter(ExecState* exec, EncodedJSValue slotParent, EncodedJSValue, PropertyName propertyName)
     587JSValue JSCallbackObject<Parent>::staticFunctionGetter(ExecState* exec, JSValue slotParent, PropertyName propertyName)
    595588{
    596589    JSCallbackObject* thisObj = asCallbackObject(slotParent);
     
    599592    PropertySlot slot2(thisObj);
    600593    if (Parent::getOwnPropertySlot(thisObj, exec, propertyName, slot2))
    601         return JSValue::encode(slot2.getValue(exec, propertyName));
     594        return slot2.getValue(exec, propertyName);
    602595
    603596    if (StringImpl* name = propertyName.publicName()) {
     
    609602                        JSObject* o = JSCallbackFunction::create(vm, thisObj->globalObject(), callAsFunction, name);
    610603                        thisObj->putDirect(vm, propertyName, o, entry->attributes);
    611                         return JSValue::encode(o);
     604                        return o;
    612605                    }
    613606                }
     
    616609    }
    617610
    618     return JSValue::encode(exec->vm().throwException(exec, createReferenceError(exec, ASCIILiteral("Static function property defined with NULL callAsFunction callback."))));
    619 }
    620 
    621 template <class Parent>
    622 EncodedJSValue JSCallbackObject<Parent>::callbackGetter(ExecState* exec, EncodedJSValue slotParent, EncodedJSValue, PropertyName propertyName)
     611    return exec->vm().throwException(exec, createReferenceError(exec, ASCIILiteral("Static function property defined with NULL callAsFunction callback.")));
     612}
     613
     614template <class Parent>
     615JSValue JSCallbackObject<Parent>::callbackGetter(ExecState* exec, JSValue slotParent, PropertyName propertyName)
    623616{
    624617    JSCallbackObject* thisObj = asCallbackObject(slotParent);
     
    640633                if (exception) {
    641634                    exec->vm().throwException(exec, toJS(exec, exception));
    642                     return JSValue::encode(jsUndefined());
     635                    return jsUndefined();
    643636                }
    644637                if (value)
    645                     return JSValue::encode(toJS(exec, value));
    646             }
    647         }
    648     }
    649 
    650     return JSValue::encode(exec->vm().throwException(exec, createReferenceError(exec, ASCIILiteral("hasProperty callback returned true for a property that doesn't exist."))));
     638                    return toJS(exec, value);
     639            }
     640        }
     641    }
     642
     643    return exec->vm().throwException(exec, createReferenceError(exec, ASCIILiteral("hasProperty callback returned true for a property that doesn't exist.")));
    651644}
    652645
  • trunk/Source/JavaScriptCore/ChangeLog

    r160186 r160204  
     12013-12-05  Commit Queue  <commit-queue@webkit.org>
     2
     3        Unreviewed, rolling out r160133.
     4        http://trac.webkit.org/changeset/160133
     5        https://bugs.webkit.org/show_bug.cgi?id=125325
     6
     7        broke bindings tests on all the bots (Requested by thorton on
     8        #webkit).
     9
     10        * API/JSCallbackObject.h:
     11        * API/JSCallbackObjectFunctions.h:
     12        (JSC::::staticFunctionGetter):
     13        (JSC::::callbackGetter):
     14        * jit/JITOperations.cpp:
     15        * runtime/JSActivation.cpp:
     16        (JSC::JSActivation::argumentsGetter):
     17        * runtime/JSActivation.h:
     18        * runtime/JSFunction.cpp:
     19        (JSC::JSFunction::argumentsGetter):
     20        (JSC::JSFunction::callerGetter):
     21        (JSC::JSFunction::lengthGetter):
     22        (JSC::JSFunction::nameGetter):
     23        * runtime/JSFunction.h:
     24        * runtime/JSObject.h:
     25        (JSC::PropertySlot::getValue):
     26        * runtime/NumberConstructor.cpp:
     27        (JSC::numberConstructorNaNValue):
     28        (JSC::numberConstructorNegInfinity):
     29        (JSC::numberConstructorPosInfinity):
     30        (JSC::numberConstructorMaxValue):
     31        (JSC::numberConstructorMinValue):
     32        * runtime/PropertySlot.h:
     33        * runtime/RegExpConstructor.cpp:
     34        (JSC::regExpConstructorDollar1):
     35        (JSC::regExpConstructorDollar2):
     36        (JSC::regExpConstructorDollar3):
     37        (JSC::regExpConstructorDollar4):
     38        (JSC::regExpConstructorDollar5):
     39        (JSC::regExpConstructorDollar6):
     40        (JSC::regExpConstructorDollar7):
     41        (JSC::regExpConstructorDollar8):
     42        (JSC::regExpConstructorDollar9):
     43        (JSC::regExpConstructorInput):
     44        (JSC::regExpConstructorMultiline):
     45        (JSC::regExpConstructorLastMatch):
     46        (JSC::regExpConstructorLastParen):
     47        (JSC::regExpConstructorLeftContext):
     48        (JSC::regExpConstructorRightContext):
     49        * runtime/RegExpObject.cpp:
     50        (JSC::regExpObjectGlobal):
     51        (JSC::regExpObjectIgnoreCase):
     52        (JSC::regExpObjectMultiline):
     53        (JSC::regExpObjectSource):
     54
    1552013-12-05  Mark Lam  <mark.lam@apple.com>
    256
  • trunk/Source/JavaScriptCore/jit/JITOperations.cpp

    r160133 r160204  
    223223    Identifier ident(vm, uid);
    224224   
    225     return function(exec, JSValue::encode(base), JSValue::encode(base), ident);
     225    return JSValue::encode(function(exec, asObject(base), ident));
    226226}
    227227
  • trunk/Source/JavaScriptCore/runtime/JSActivation.cpp

    r160133 r160204  
    211211}
    212212
    213 EncodedJSValue JSActivation::argumentsGetter(ExecState*, EncodedJSValue slotBase, EncodedJSValue, PropertyName)
    214 {
    215     JSActivation* activation = jsCast<JSActivation*>(JSValue::decode(slotBase));
     213JSValue JSActivation::argumentsGetter(ExecState*, JSValue slotBase, PropertyName)
     214{
     215    JSActivation* activation = jsCast<JSActivation*>(slotBase);
    216216    CallFrame* callFrame = CallFrame::create(reinterpret_cast<Register*>(activation->m_registers));
    217217    ASSERT(!activation->isTornOff() && (callFrame->codeBlock()->usesArguments() || callFrame->codeBlock()->usesEval()));
    218218    if (activation->isTornOff() || !(callFrame->codeBlock()->usesArguments() || callFrame->codeBlock()->usesEval()))
    219         return JSValue::encode(jsUndefined());
     219        return jsUndefined();
    220220
    221221    VirtualRegister argumentsRegister = callFrame->codeBlock()->argumentsRegister();
    222222    if (JSValue arguments = callFrame->uncheckedR(argumentsRegister.offset()).jsValue())
    223         return JSValue::encode(arguments);
     223        return arguments;
    224224    int realArgumentsRegister = unmodifiedArgumentsRegister(argumentsRegister).offset();
    225225
     
    229229   
    230230    ASSERT(callFrame->uncheckedR(realArgumentsRegister).jsValue().inherits(Arguments::info()));
    231     return JSValue::encode(callFrame->uncheckedR(realArgumentsRegister).jsValue());
     231    return callFrame->uncheckedR(realArgumentsRegister).jsValue();
    232232}
    233233
  • trunk/Source/JavaScriptCore/runtime/JSActivation.h

    r160133 r160204  
    101101    bool symbolTablePutWithAttributes(VM&, PropertyName, JSValue, unsigned attributes);
    102102
    103     static EncodedJSValue argumentsGetter(ExecState*, EncodedJSValue, EncodedJSValue, PropertyName);
     103    static JSValue argumentsGetter(ExecState*, JSValue, PropertyName);
    104104
    105105    static size_t allocationSize(SymbolTable*);
  • trunk/Source/JavaScriptCore/runtime/JSFunction.cpp

    r160133 r160204  
    213213}
    214214
    215 EncodedJSValue JSFunction::argumentsGetter(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, PropertyName)
    216 {
    217     JSFunction* thisObj = jsCast<JSFunction*>(JSValue::decode(slotBase));
     215JSValue JSFunction::argumentsGetter(ExecState* exec, JSValue slotBase, PropertyName)
     216{
     217    JSFunction* thisObj = jsCast<JSFunction*>(slotBase);
    218218    ASSERT(!thisObj->isHostFunction());
    219219
    220     return JSValue::encode(retrieveArguments(exec, thisObj));
     220    return retrieveArguments(exec, thisObj);
    221221}
    222222
     
    268268}
    269269
    270 EncodedJSValue JSFunction::callerGetter(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, PropertyName)
    271 {
    272     JSFunction* thisObj = jsCast<JSFunction*>(JSValue::decode(slotBase));
     270JSValue JSFunction::callerGetter(ExecState* exec, JSValue slotBase, PropertyName)
     271{
     272    JSFunction* thisObj = jsCast<JSFunction*>(slotBase);
    273273    ASSERT(!thisObj->isHostFunction());
    274274    JSValue caller = retrieveCallerFunction(exec, thisObj);
     
    276276    // See ES5.1 15.3.5.4 - Function.caller may not be used to retrieve a strict caller.
    277277    if (!caller.isObject() || !asObject(caller)->inherits(JSFunction::info()))
    278         return JSValue::encode(caller);
     278        return caller;
    279279    JSFunction* function = jsCast<JSFunction*>(caller);
    280280    if (function->isHostFunction() || !function->jsExecutable()->isStrictMode())
    281         return JSValue::encode(caller);
    282     return JSValue::encode(throwTypeError(exec, ASCIILiteral("Function.caller used to retrieve strict caller")));
    283 }
    284 
    285 EncodedJSValue JSFunction::lengthGetter(ExecState*, EncodedJSValue slotBase, EncodedJSValue, PropertyName)
    286 {
    287     JSFunction* thisObj = jsCast<JSFunction*>(JSValue::decode(slotBase));
     281        return caller;
     282    return throwTypeError(exec, ASCIILiteral("Function.caller used to retrieve strict caller"));
     283}
     284
     285JSValue JSFunction::lengthGetter(ExecState*, JSValue slotBase, PropertyName)
     286{
     287    JSFunction* thisObj = jsCast<JSFunction*>(slotBase);
    288288    ASSERT(!thisObj->isHostFunction());
    289     return JSValue::encode(jsNumber(thisObj->jsExecutable()->parameterCount()));
    290 }
    291 
    292 EncodedJSValue JSFunction::nameGetter(ExecState*, EncodedJSValue slotBase, EncodedJSValue, PropertyName)
    293 {
    294     JSFunction* thisObj = jsCast<JSFunction*>(JSValue::decode(slotBase));
     289    return jsNumber(thisObj->jsExecutable()->parameterCount());
     290}
     291
     292JSValue JSFunction::nameGetter(ExecState*, JSValue slotBase, PropertyName)
     293{
     294    JSFunction* thisObj = jsCast<JSFunction*>(slotBase);
    295295    ASSERT(!thisObj->isHostFunction());
    296     return JSValue::encode(thisObj->jsExecutable()->nameValue());
     296    return thisObj->jsExecutable()->nameValue();
    297297}
    298298
  • trunk/Source/JavaScriptCore/runtime/JSFunction.h

    r160133 r160204  
    172172        JS_EXPORT_PRIVATE bool isHostFunctionNonInline() const;
    173173
    174         static EncodedJSValue argumentsGetter(ExecState*, EncodedJSValue, EncodedJSValue, PropertyName);
    175         static EncodedJSValue callerGetter(ExecState*, EncodedJSValue, EncodedJSValue, PropertyName);
    176         static EncodedJSValue lengthGetter(ExecState*, EncodedJSValue, EncodedJSValue, PropertyName);
    177         static EncodedJSValue nameGetter(ExecState*, EncodedJSValue, EncodedJSValue, PropertyName);
     174        static JSValue argumentsGetter(ExecState*, JSValue, PropertyName);
     175        static JSValue callerGetter(ExecState*, JSValue, PropertyName);
     176        static JSValue lengthGetter(ExecState*, JSValue, PropertyName);
     177        static JSValue nameGetter(ExecState*, JSValue, PropertyName);
    178178
    179179        WriteBarrier<ExecutableBase> m_executable;
  • trunk/Source/JavaScriptCore/runtime/JSObject.h

    r160133 r160204  
    15361536        return JSValue::decode(m_data.value);
    15371537    if (m_propertyType == TypeCustomIndex)
    1538         return JSValue::decode(m_data.customIndex.getIndexValue(exec, JSValue::encode(slotBase()), JSValue::encode(m_thisValue), m_data.customIndex.index));
     1538        return m_data.customIndex.getIndexValue(exec, slotBase(), m_data.customIndex.index);
    15391539    if (m_propertyType == TypeGetter)
    15401540        return functionGetter(exec);
    1541     return JSValue::decode(m_data.custom.getValue(exec, JSValue::encode(slotBase()), JSValue::encode(m_thisValue), propertyName));
     1541    return m_data.custom.getValue(exec, slotBase(), propertyName);
    15421542}
    15431543
     
    15471547        return JSValue::decode(m_data.value);
    15481548    if (m_propertyType == TypeCustomIndex)
    1549         return JSValue::decode(m_data.customIndex.getIndexValue(exec, JSValue::encode(slotBase()), JSValue::encode(m_thisValue), m_data.customIndex.index));
     1549        return m_data.customIndex.getIndexValue(exec, slotBase(), m_data.customIndex.index);
    15501550    if (m_propertyType == TypeGetter)
    15511551        return functionGetter(exec);
    1552     return JSValue::decode(m_data.custom.getValue(exec, JSValue::encode(slotBase()), JSValue::encode(m_thisValue), Identifier::from(exec, propertyName)));
     1552    return m_data.custom.getValue(exec, slotBase(), Identifier::from(exec, propertyName));
    15531553}
    15541554
  • trunk/Source/JavaScriptCore/runtime/NumberConstructor.cpp

    r160133 r160204  
    3030namespace JSC {
    3131
    32 static EncodedJSValue numberConstructorNaNValue(ExecState*, EncodedJSValue, EncodedJSValue, PropertyName);
    33 static EncodedJSValue numberConstructorNegInfinity(ExecState*, EncodedJSValue, EncodedJSValue, PropertyName);
    34 static EncodedJSValue numberConstructorPosInfinity(ExecState*, EncodedJSValue, EncodedJSValue, PropertyName);
    35 static EncodedJSValue numberConstructorMaxValue(ExecState*, EncodedJSValue, EncodedJSValue, PropertyName);
    36 static EncodedJSValue numberConstructorMinValue(ExecState*, EncodedJSValue, EncodedJSValue, PropertyName);
     32static JSValue numberConstructorNaNValue(ExecState*, JSValue, PropertyName);
     33static JSValue numberConstructorNegInfinity(ExecState*, JSValue, PropertyName);
     34static JSValue numberConstructorPosInfinity(ExecState*, JSValue, PropertyName);
     35static JSValue numberConstructorMaxValue(ExecState*, JSValue, PropertyName);
     36static JSValue numberConstructorMinValue(ExecState*, JSValue, PropertyName);
    3737
    3838} // namespace JSC
     
    8383}
    8484
    85 static EncodedJSValue numberConstructorNaNValue(ExecState*, EncodedJSValue, EncodedJSValue, PropertyName)
     85static JSValue numberConstructorNaNValue(ExecState*, JSValue, PropertyName)
    8686{
    87     return JSValue::encode(jsNaN());
     87    return jsNaN();
    8888}
    8989
    90 static EncodedJSValue numberConstructorNegInfinity(ExecState*, EncodedJSValue, EncodedJSValue, PropertyName)
     90static JSValue numberConstructorNegInfinity(ExecState*, JSValue, PropertyName)
    9191{
    92     return JSValue::encode(jsNumber(-std::numeric_limits<double>::infinity()));
     92    return jsNumber(-std::numeric_limits<double>::infinity());
    9393}
    9494
    95 static EncodedJSValue numberConstructorPosInfinity(ExecState*, EncodedJSValue, EncodedJSValue, PropertyName)
     95static JSValue numberConstructorPosInfinity(ExecState*, JSValue, PropertyName)
    9696{
    97     return JSValue::encode(jsNumber(std::numeric_limits<double>::infinity()));
     97    return jsNumber(std::numeric_limits<double>::infinity());
    9898}
    9999
    100 static EncodedJSValue numberConstructorMaxValue(ExecState*, EncodedJSValue, EncodedJSValue, PropertyName)
     100static JSValue numberConstructorMaxValue(ExecState*, JSValue, PropertyName)
    101101{
    102     return JSValue::encode(jsNumber(1.7976931348623157E+308));
     102    return jsNumber(1.7976931348623157E+308);
    103103}
    104104
    105 static EncodedJSValue numberConstructorMinValue(ExecState*, EncodedJSValue, EncodedJSValue, PropertyName)
     105static JSValue numberConstructorMinValue(ExecState*, JSValue, PropertyName)
    106106{
    107     return JSValue::encode(jsNumber(5E-324));
     107    return jsNumber(5E-324);
    108108}
    109109
  • trunk/Source/JavaScriptCore/runtime/PropertySlot.h

    r160133 r160204  
    6161    }
    6262
    63     typedef EncodedJSValue (*GetValueFunc)(ExecState*, EncodedJSValue slotBase, EncodedJSValue thisValue, PropertyName);
    64     typedef EncodedJSValue (*GetIndexValueFunc)(ExecState*, EncodedJSValue slotBase, EncodedJSValue thisValue, unsigned);
     63    typedef JSValue (*GetValueFunc)(ExecState*, JSValue slotBase, PropertyName);
     64    typedef JSValue (*GetIndexValueFunc)(ExecState*, JSValue slotBase, unsigned);
    6565
    6666    JSValue getValue(ExecState*, PropertyName) const;
     
    227227    PropertyType m_propertyType;
    228228    PropertyOffset m_offset;
    229     const JSValue m_thisValue;
     229    JSValue m_thisValue;
    230230    JSObject* m_slotBase;
    231231};
  • trunk/Source/JavaScriptCore/runtime/RegExpConstructor.cpp

    r160133 r160204  
    3030namespace JSC {
    3131
    32 static EncodedJSValue regExpConstructorInput(ExecState*, EncodedJSValue, EncodedJSValue, PropertyName);
    33 static EncodedJSValue regExpConstructorMultiline(ExecState*, EncodedJSValue, EncodedJSValue, PropertyName);
    34 static EncodedJSValue regExpConstructorLastMatch(ExecState*, EncodedJSValue, EncodedJSValue, PropertyName);
    35 static EncodedJSValue regExpConstructorLastParen(ExecState*, EncodedJSValue, EncodedJSValue, PropertyName);
    36 static EncodedJSValue regExpConstructorLeftContext(ExecState*, EncodedJSValue, EncodedJSValue, PropertyName);
    37 static EncodedJSValue regExpConstructorRightContext(ExecState*, EncodedJSValue, EncodedJSValue, PropertyName);
    38 static EncodedJSValue regExpConstructorDollar1(ExecState*, EncodedJSValue, EncodedJSValue, PropertyName);
    39 static EncodedJSValue regExpConstructorDollar2(ExecState*, EncodedJSValue, EncodedJSValue, PropertyName);
    40 static EncodedJSValue regExpConstructorDollar3(ExecState*, EncodedJSValue, EncodedJSValue, PropertyName);
    41 static EncodedJSValue regExpConstructorDollar4(ExecState*, EncodedJSValue, EncodedJSValue, PropertyName);
    42 static EncodedJSValue regExpConstructorDollar5(ExecState*, EncodedJSValue, EncodedJSValue, PropertyName);
    43 static EncodedJSValue regExpConstructorDollar6(ExecState*, EncodedJSValue, EncodedJSValue, PropertyName);
    44 static EncodedJSValue regExpConstructorDollar7(ExecState*, EncodedJSValue, EncodedJSValue, PropertyName);
    45 static EncodedJSValue regExpConstructorDollar8(ExecState*, EncodedJSValue, EncodedJSValue, PropertyName);
    46 static EncodedJSValue regExpConstructorDollar9(ExecState*, EncodedJSValue, EncodedJSValue, PropertyName);
     32static JSValue regExpConstructorInput(ExecState*, JSValue, PropertyName);
     33static JSValue regExpConstructorMultiline(ExecState*, JSValue, PropertyName);
     34static JSValue regExpConstructorLastMatch(ExecState*, JSValue, PropertyName);
     35static JSValue regExpConstructorLastParen(ExecState*, JSValue, PropertyName);
     36static JSValue regExpConstructorLeftContext(ExecState*, JSValue, PropertyName);
     37static JSValue regExpConstructorRightContext(ExecState*, JSValue, PropertyName);
     38static JSValue regExpConstructorDollar1(ExecState*, JSValue, PropertyName);
     39static JSValue regExpConstructorDollar2(ExecState*, JSValue, PropertyName);
     40static JSValue regExpConstructorDollar3(ExecState*, JSValue, PropertyName);
     41static JSValue regExpConstructorDollar4(ExecState*, JSValue, PropertyName);
     42static JSValue regExpConstructorDollar5(ExecState*, JSValue, PropertyName);
     43static JSValue regExpConstructorDollar6(ExecState*, JSValue, PropertyName);
     44static JSValue regExpConstructorDollar7(ExecState*, JSValue, PropertyName);
     45static JSValue regExpConstructorDollar8(ExecState*, JSValue, PropertyName);
     46static JSValue regExpConstructorDollar9(ExecState*, JSValue, PropertyName);
    4747
    4848static void setRegExpConstructorInput(ExecState*, JSObject*, JSValue);
     
    159159}
    160160
    161 static inline RegExpConstructor* asRegExpConstructor(EncodedJSValue value)
    162 {
    163     return jsCast<RegExpConstructor*>(JSValue::decode(value));
    164 }
    165    
    166 EncodedJSValue regExpConstructorDollar1(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, PropertyName)
    167 {
    168     return JSValue::encode(asRegExpConstructor(slotBase)->getBackref(exec, 1));
    169 }
    170 
    171 EncodedJSValue regExpConstructorDollar2(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, PropertyName)
    172 {
    173     return JSValue::encode(asRegExpConstructor(slotBase)->getBackref(exec, 2));
    174 }
    175 
    176 EncodedJSValue regExpConstructorDollar3(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, PropertyName)
    177 {
    178     return JSValue::encode(asRegExpConstructor(slotBase)->getBackref(exec, 3));
    179 }
    180 
    181 EncodedJSValue regExpConstructorDollar4(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, PropertyName)
    182 {
    183     return JSValue::encode(asRegExpConstructor(slotBase)->getBackref(exec, 4));
    184 }
    185 
    186 EncodedJSValue regExpConstructorDollar5(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, PropertyName)
    187 {
    188     return JSValue::encode(asRegExpConstructor(slotBase)->getBackref(exec, 5));
    189 }
    190 
    191 EncodedJSValue regExpConstructorDollar6(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, PropertyName)
    192 {
    193     return JSValue::encode(asRegExpConstructor(slotBase)->getBackref(exec, 6));
    194 }
    195 
    196 EncodedJSValue regExpConstructorDollar7(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, PropertyName)
    197 {
    198     return JSValue::encode(asRegExpConstructor(slotBase)->getBackref(exec, 7));
    199 }
    200 
    201 EncodedJSValue regExpConstructorDollar8(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, PropertyName)
    202 {
    203     return JSValue::encode(asRegExpConstructor(slotBase)->getBackref(exec, 8));
    204 }
    205 
    206 EncodedJSValue regExpConstructorDollar9(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, PropertyName)
    207 {
    208     return JSValue::encode(asRegExpConstructor(slotBase)->getBackref(exec, 9));
    209 }
    210 
    211 EncodedJSValue regExpConstructorInput(ExecState*, EncodedJSValue slotBase, EncodedJSValue, PropertyName)
    212 {
    213     return JSValue::encode(asRegExpConstructor(slotBase)->input());
    214 }
    215 
    216 EncodedJSValue regExpConstructorMultiline(ExecState*, EncodedJSValue slotBase, EncodedJSValue, PropertyName)
    217 {
    218     return JSValue::encode(jsBoolean(asRegExpConstructor(slotBase)->multiline()));
    219 }
    220 
    221 EncodedJSValue regExpConstructorLastMatch(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, PropertyName)
    222 {
    223     return JSValue::encode(asRegExpConstructor(slotBase)->getBackref(exec, 0));
    224 }
    225 
    226 EncodedJSValue regExpConstructorLastParen(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, PropertyName)
    227 {
    228     return JSValue::encode(asRegExpConstructor(slotBase)->getLastParen(exec));
    229 }
    230 
    231 EncodedJSValue regExpConstructorLeftContext(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, PropertyName)
    232 {
    233     return JSValue::encode(asRegExpConstructor(slotBase)->getLeftContext(exec));
    234 }
    235 
    236 EncodedJSValue regExpConstructorRightContext(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, PropertyName)
    237 {
    238     return JSValue::encode(asRegExpConstructor(slotBase)->getRightContext(exec));
     161JSValue regExpConstructorDollar1(ExecState* exec, JSValue slotBase, PropertyName)
     162{
     163    return asRegExpConstructor(slotBase)->getBackref(exec, 1);
     164}
     165
     166JSValue regExpConstructorDollar2(ExecState* exec, JSValue slotBase, PropertyName)
     167{
     168    return asRegExpConstructor(slotBase)->getBackref(exec, 2);
     169}
     170
     171JSValue regExpConstructorDollar3(ExecState* exec, JSValue slotBase, PropertyName)
     172{
     173    return asRegExpConstructor(slotBase)->getBackref(exec, 3);
     174}
     175
     176JSValue regExpConstructorDollar4(ExecState* exec, JSValue slotBase, PropertyName)
     177{
     178    return asRegExpConstructor(slotBase)->getBackref(exec, 4);
     179}
     180
     181JSValue regExpConstructorDollar5(ExecState* exec, JSValue slotBase, PropertyName)
     182{
     183    return asRegExpConstructor(slotBase)->getBackref(exec, 5);
     184}
     185
     186JSValue regExpConstructorDollar6(ExecState* exec, JSValue slotBase, PropertyName)
     187{
     188    return asRegExpConstructor(slotBase)->getBackref(exec, 6);
     189}
     190
     191JSValue regExpConstructorDollar7(ExecState* exec, JSValue slotBase, PropertyName)
     192{
     193    return asRegExpConstructor(slotBase)->getBackref(exec, 7);
     194}
     195
     196JSValue regExpConstructorDollar8(ExecState* exec, JSValue slotBase, PropertyName)
     197{
     198    return asRegExpConstructor(slotBase)->getBackref(exec, 8);
     199}
     200
     201JSValue regExpConstructorDollar9(ExecState* exec, JSValue slotBase, PropertyName)
     202{
     203    return asRegExpConstructor(slotBase)->getBackref(exec, 9);
     204}
     205
     206JSValue regExpConstructorInput(ExecState*, JSValue slotBase, PropertyName)
     207{
     208    return asRegExpConstructor(slotBase)->input();
     209}
     210
     211JSValue regExpConstructorMultiline(ExecState*, JSValue slotBase, PropertyName)
     212{
     213    return jsBoolean(asRegExpConstructor(slotBase)->multiline());
     214}
     215
     216JSValue regExpConstructorLastMatch(ExecState* exec, JSValue slotBase, PropertyName)
     217{
     218    return asRegExpConstructor(slotBase)->getBackref(exec, 0);
     219}
     220
     221JSValue regExpConstructorLastParen(ExecState* exec, JSValue slotBase, PropertyName)
     222{
     223    return asRegExpConstructor(slotBase)->getLastParen(exec);
     224}
     225
     226JSValue regExpConstructorLeftContext(ExecState* exec, JSValue slotBase, PropertyName)
     227{
     228    return asRegExpConstructor(slotBase)->getLeftContext(exec);
     229}
     230
     231JSValue regExpConstructorRightContext(ExecState* exec, JSValue slotBase, PropertyName)
     232{
     233    return asRegExpConstructor(slotBase)->getRightContext(exec);
    239234}
    240235
  • trunk/Source/JavaScriptCore/runtime/RegExpObject.cpp

    r160133 r160204  
    4040namespace JSC {
    4141
    42 static EncodedJSValue regExpObjectGlobal(ExecState*, EncodedJSValue, EncodedJSValue, PropertyName);
    43 static EncodedJSValue regExpObjectIgnoreCase(ExecState*, EncodedJSValue, EncodedJSValue, PropertyName);
    44 static EncodedJSValue regExpObjectMultiline(ExecState*, EncodedJSValue, EncodedJSValue, PropertyName);
    45 static EncodedJSValue regExpObjectSource(ExecState*, EncodedJSValue, EncodedJSValue, PropertyName);
     42static JSValue regExpObjectGlobal(ExecState*, JSValue, PropertyName);
     43static JSValue regExpObjectIgnoreCase(ExecState*, JSValue, PropertyName);
     44static JSValue regExpObjectMultiline(ExecState*, JSValue, PropertyName);
     45static JSValue regExpObjectSource(ExecState*, JSValue, PropertyName);
    4646
    4747} // namespace JSC
     
    156156}
    157157
    158 static inline RegExpObject* asRegExpObject(EncodedJSValue value)
    159 {
    160     return jsCast<RegExpObject*>(JSValue::decode(value));
    161 }
    162 
    163 EncodedJSValue regExpObjectGlobal(ExecState*, EncodedJSValue slotBase, EncodedJSValue, PropertyName)
    164 {
    165     return JSValue::encode(jsBoolean(asRegExpObject(slotBase)->regExp()->global()));
    166 }
    167 
    168 EncodedJSValue regExpObjectIgnoreCase(ExecState*, EncodedJSValue slotBase, EncodedJSValue, PropertyName)
    169 {
    170     return JSValue::encode(jsBoolean(asRegExpObject(slotBase)->regExp()->ignoreCase()));
     158JSValue regExpObjectGlobal(ExecState*, JSValue slotBase, PropertyName)
     159{
     160    return jsBoolean(asRegExpObject(slotBase)->regExp()->global());
     161}
     162
     163JSValue regExpObjectIgnoreCase(ExecState*, JSValue slotBase, PropertyName)
     164{
     165    return jsBoolean(asRegExpObject(slotBase)->regExp()->ignoreCase());
    171166}
    172167 
    173 EncodedJSValue regExpObjectMultiline(ExecState*, EncodedJSValue slotBase, EncodedJSValue, PropertyName)
     168JSValue regExpObjectMultiline(ExecState*, JSValue slotBase, PropertyName)
    174169{           
    175     return JSValue::encode(jsBoolean(asRegExpObject(slotBase)->regExp()->multiline()));
     170    return jsBoolean(asRegExpObject(slotBase)->regExp()->multiline());
    176171}
    177172
     
    282277}
    283278
    284    
    285    
    286 EncodedJSValue regExpObjectSource(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, PropertyName)
     279JSValue regExpObjectSource(ExecState* exec, JSValue slotBase, PropertyName)
    287280{
    288281    String pattern = asRegExpObject(slotBase)->regExp()->pattern();
    289282    if (pattern.is8Bit())
    290         return JSValue::encode(regExpObjectSourceInternal(exec, pattern, pattern.characters8(), pattern.length()));
    291     return JSValue::encode(regExpObjectSourceInternal(exec, pattern, pattern.characters16(), pattern.length()));
     283        return regExpObjectSourceInternal(exec, pattern, pattern.characters8(), pattern.length());
     284    return regExpObjectSourceInternal(exec, pattern, pattern.characters16(), pattern.length());
    292285}
    293286
  • trunk/Source/WebCore/ChangeLog

    r160203 r160204  
     12013-12-05  Commit Queue  <commit-queue@webkit.org>
     2
     3        Unreviewed, rolling out r160133.
     4        http://trac.webkit.org/changeset/160133
     5        https://bugs.webkit.org/show_bug.cgi?id=125325
     6
     7        broke bindings tests on all the bots (Requested by thorton on
     8        #webkit).
     9
     10        * bindings/js/JSCSSStyleDeclarationCustom.cpp:
     11        (WebCore::cssPropertyGetterPixelOrPosPrefixCallback):
     12        (WebCore::cssPropertyGetterCallback):
     13        * bindings/js/JSDOMBinding.cpp:
     14        (WebCore::objectToStringFunctionGetter):
     15        * bindings/js/JSDOMBinding.h:
     16        * bindings/js/JSDOMMimeTypeArrayCustom.cpp:
     17        (WebCore::JSDOMMimeTypeArray::nameGetter):
     18        * bindings/js/JSDOMPluginArrayCustom.cpp:
     19        (WebCore::JSDOMPluginArray::nameGetter):
     20        * bindings/js/JSDOMPluginCustom.cpp:
     21        (WebCore::JSDOMPlugin::nameGetter):
     22        * bindings/js/JSDOMStringMapCustom.cpp:
     23        (WebCore::JSDOMStringMap::nameGetter):
     24        * bindings/js/JSDOMWindowCustom.cpp:
     25        (WebCore::nonCachingStaticFunctionGetter):
     26        (WebCore::childFrameGetter):
     27        (WebCore::indexGetter):
     28        (WebCore::namedItemGetter):
     29        * bindings/js/JSHTMLAllCollectionCustom.cpp:
     30        (WebCore::JSHTMLAllCollection::nameGetter):
     31        * bindings/js/JSHTMLCollectionCustom.cpp:
     32        (WebCore::JSHTMLCollection::nameGetter):
     33        * bindings/js/JSHTMLDocumentCustom.cpp:
     34        (WebCore::JSHTMLDocument::nameGetter):
     35        * bindings/js/JSHTMLFormControlsCollectionCustom.cpp:
     36        (WebCore::JSHTMLFormControlsCollection::nameGetter):
     37        * bindings/js/JSHTMLFormElementCustom.cpp:
     38        (WebCore::JSHTMLFormElement::nameGetter):
     39        * bindings/js/JSHTMLFrameSetElementCustom.cpp:
     40        (WebCore::JSHTMLFrameSetElement::nameGetter):
     41        * bindings/js/JSHistoryCustom.cpp:
     42        (WebCore::nonCachingStaticBackFunctionGetter):
     43        (WebCore::nonCachingStaticForwardFunctionGetter):
     44        (WebCore::nonCachingStaticGoFunctionGetter):
     45        * bindings/js/JSJavaScriptCallFrameCustom.cpp:
     46        (WebCore::JSJavaScriptCallFrame::scopeType):
     47        * bindings/js/JSLocationCustom.cpp:
     48        (WebCore::nonCachingStaticReplaceFunctionGetter):
     49        (WebCore::nonCachingStaticReloadFunctionGetter):
     50        (WebCore::nonCachingStaticAssignFunctionGetter):
     51        * bindings/js/JSNamedNodeMapCustom.cpp:
     52        (WebCore::JSNamedNodeMap::nameGetter):
     53        * bindings/js/JSNodeListCustom.cpp:
     54        (WebCore::JSNodeList::nameGetter):
     55        * bindings/js/JSPluginElementFunctions.cpp:
     56        (WebCore::pluginElementPropertyGetter):
     57        * bindings/js/JSPluginElementFunctions.h:
     58        * bindings/js/JSRTCStatsResponseCustom.cpp:
     59        (WebCore::JSRTCStatsResponse::nameGetter):
     60        * bindings/js/JSStorageCustom.cpp:
     61        (WebCore::JSStorage::nameGetter):
     62        * bindings/js/JSStyleSheetListCustom.cpp:
     63        (WebCore::JSStyleSheetList::nameGetter):
     64        * bindings/scripts/CodeGeneratorJS.pm:
     65        (GenerateHeader):
     66        (GenerateImplementation):
     67        (GenerateParametersCheck):
     68        * bridge/runtime_array.cpp:
     69        (JSC::RuntimeArray::lengthGetter):
     70        (JSC::RuntimeArray::indexGetter):
     71        * bridge/runtime_array.h:
     72        * bridge/runtime_method.cpp:
     73        (JSC::RuntimeMethod::lengthGetter):
     74        * bridge/runtime_method.h:
     75        * bridge/runtime_object.cpp:
     76        (JSC::Bindings::RuntimeObject::fallbackObjectGetter):
     77        (JSC::Bindings::RuntimeObject::fieldGetter):
     78        (JSC::Bindings::RuntimeObject::methodGetter):
     79        * bridge/runtime_object.h:
     80
    1812013-12-05  Seokju Kwon  <seokju@webkit.org>
    282
  • trunk/Source/WebCore/bindings/js/JSCSSStyleDeclarationCustom.cpp

    r160133 r160204  
    304304}
    305305
    306 static EncodedJSValue cssPropertyGetterPixelOrPosPrefixCallback(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, unsigned propertyID)
    307 {
    308     return JSValue::encode(cssPropertyGetterPixelOrPosPrefix(exec, jsCast<JSCSSStyleDeclaration*>(JSValue::decode(slotBase)), propertyID));
     306static JSValue cssPropertyGetterPixelOrPosPrefixCallback(ExecState* exec, JSValue slotBase, unsigned propertyID)
     307{
     308    return cssPropertyGetterPixelOrPosPrefix(exec, jsCast<JSCSSStyleDeclaration*>(asObject(slotBase)), propertyID);
    309309}
    310310
     
    318318}
    319319
    320 static EncodedJSValue cssPropertyGetterCallback(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, unsigned propertyID)
    321 {
    322     return JSValue::encode(cssPropertyGetter(exec, jsCast<JSCSSStyleDeclaration*>(JSValue::decode(slotBase)), propertyID));
     320static JSValue cssPropertyGetterCallback(ExecState* exec, JSValue slotBase, unsigned propertyID)
     321{
     322    return cssPropertyGetter(exec, jsCast<JSCSSStyleDeclaration*>(asObject(slotBase)), propertyID);
    323323}
    324324
  • trunk/Source/WebCore/bindings/js/JSDOMBinding.cpp

    r160133 r160204  
    272272}
    273273
    274 EncodedJSValue objectToStringFunctionGetter(ExecState* exec, EncodedJSValue, EncodedJSValue, PropertyName propertyName)
    275 {
    276     return JSValue::encode(JSFunction::create(exec->vm(), exec->lexicalGlobalObject(), 0, propertyName.publicName(), objectProtoFuncToString));
     274JSValue objectToStringFunctionGetter(ExecState* exec, JSValue, PropertyName propertyName)
     275{
     276    return JSFunction::create(exec->vm(), exec->lexicalGlobalObject(), 0, propertyName.publicName(), objectProtoFuncToString);
    277277}
    278278
  • trunk/Source/WebCore/bindings/js/JSDOMBinding.h

    r160133 r160204  
    573573
    574574void printErrorMessageForFrame(Frame*, const String& message);
    575 JSC::EncodedJSValue objectToStringFunctionGetter(JSC::ExecState*, JSC::EncodedJSValue, JSC::EncodedJSValue, JSC::PropertyName);
     575JSC::JSValue objectToStringFunctionGetter(JSC::ExecState*, JSC::JSValue, JSC::PropertyName);
    576576
    577577inline JSC::JSValue jsStringWithCache(JSC::ExecState* exec, const String& s)
  • trunk/Source/WebCore/bindings/js/JSDOMMimeTypeArrayCustom.cpp

    r160133 r160204  
    3434}
    3535
    36 EncodedJSValue JSDOMMimeTypeArray::nameGetter(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, PropertyName propertyName)
     36JSValue JSDOMMimeTypeArray::nameGetter(ExecState* exec, JSValue slotBase, PropertyName propertyName)
    3737{
    38     JSDOMMimeTypeArray* thisObj = jsDynamicCast<JSDOMMimeTypeArray*>(JSValue::decode(slotBase));
    39     if (!thisObj)
    40         return throwVMTypeError(exec);
    41     return JSValue::encode(toJS(exec, thisObj->globalObject(), thisObj->impl().namedItem(propertyNameToAtomicString(propertyName))));
     38    JSDOMMimeTypeArray* thisObj = jsCast<JSDOMMimeTypeArray*>(asObject(slotBase));
     39    return toJS(exec, thisObj->globalObject(), thisObj->impl().namedItem(propertyNameToAtomicString(propertyName)));
    4240}
    4341
  • trunk/Source/WebCore/bindings/js/JSDOMPluginArrayCustom.cpp

    r160133 r160204  
    3434}
    3535
    36 EncodedJSValue JSDOMPluginArray::nameGetter(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, PropertyName propertyName)
     36JSValue JSDOMPluginArray::nameGetter(ExecState* exec, JSValue slotBase, PropertyName propertyName)
    3737{
    38     JSDOMPluginArray* thisObj = jsCast<JSDOMPluginArray*>(JSValue::decode(slotBase));
    39     return JSValue::encode(toJS(exec, thisObj->globalObject(), thisObj->impl().namedItem(propertyNameToAtomicString(propertyName))));
     38    JSDOMPluginArray* thisObj = jsCast<JSDOMPluginArray*>(asObject(slotBase));
     39    return toJS(exec, thisObj->globalObject(), thisObj->impl().namedItem(propertyNameToAtomicString(propertyName)));
    4040}
    4141
  • trunk/Source/WebCore/bindings/js/JSDOMPluginCustom.cpp

    r160133 r160204  
    3333}
    3434
    35 EncodedJSValue JSDOMPlugin::nameGetter(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, PropertyName propertyName)
     35JSValue JSDOMPlugin::nameGetter(ExecState* exec, JSValue slotBase, PropertyName propertyName)
    3636{
    37     JSDOMPlugin* thisObj = jsCast<JSDOMPlugin*>(JSValue::decode(slotBase));
    38     return JSValue::encode(toJS(exec, thisObj->globalObject(), thisObj->impl().namedItem(propertyNameToAtomicString(propertyName))));
     37    JSDOMPlugin* thisObj = jsCast<JSDOMPlugin*>(asObject(slotBase));
     38    return toJS(exec, thisObj->globalObject(), thisObj->impl().namedItem(propertyNameToAtomicString(propertyName)));
    3939}
    4040
  • trunk/Source/WebCore/bindings/js/JSDOMStringMapCustom.cpp

    r160133 r160204  
    4141}
    4242
    43 EncodedJSValue JSDOMStringMap::nameGetter(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, PropertyName propertyName)
     43JSValue JSDOMStringMap::nameGetter(ExecState* exec, JSValue slotBase, PropertyName propertyName)
    4444{
    45     JSDOMStringMap* thisObj = jsCast<JSDOMStringMap*>(JSValue::decode(slotBase));
    46     return JSValue::encode(jsStringWithCache(exec, thisObj->impl().item(propertyNameToAtomicString(propertyName))));
     45    JSDOMStringMap* thisObj = jsCast<JSDOMStringMap*>(asObject(slotBase));
     46    return jsStringWithCache(exec, thisObj->impl().item(propertyNameToAtomicString(propertyName)));
    4747}
    4848
  • trunk/Source/WebCore/bindings/js/JSDOMWindowCustom.cpp

    r160133 r160204  
    6868
    6969template<NativeFunction nativeFunction, int length>
    70 EncodedJSValue nonCachingStaticFunctionGetter(ExecState* exec, EncodedJSValue, EncodedJSValue, PropertyName propertyName)
    71 {
    72     return JSValue::encode(JSFunction::create(exec->vm(), exec->lexicalGlobalObject(), length, propertyName.publicName(), nativeFunction));
    73 }
    74 
    75 static EncodedJSValue childFrameGetter(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, PropertyName propertyName)
    76 {
    77     return JSValue::encode(toJS(exec, jsCast<JSDOMWindow*>(JSValue::decode(slotBase))->impl().frame()->tree().scopedChild(propertyNameToAtomicString(propertyName))->document()->domWindow()));
    78 }
    79 
    80 static EncodedJSValue indexGetter(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, unsigned index)
    81 {
    82     return JSValue::encode(toJS(exec, jsCast<JSDOMWindow*>(JSValue::decode(slotBase))->impl().frame()->tree().scopedChild(index)->document()->domWindow()));
    83 }
    84 
    85 static EncodedJSValue namedItemGetter(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, PropertyName propertyName)
    86 {
    87     JSDOMWindowBase* thisObj = jsCast<JSDOMWindow*>(JSValue::decode(slotBase));
     70JSValue nonCachingStaticFunctionGetter(ExecState* exec, JSValue, PropertyName propertyName)
     71{
     72    return JSFunction::create(exec->vm(), exec->lexicalGlobalObject(), length, propertyName.publicName(), nativeFunction);
     73}
     74
     75static JSValue childFrameGetter(ExecState* exec, JSValue slotBase, PropertyName propertyName)
     76{
     77    return toJS(exec, jsCast<JSDOMWindow*>(asObject(slotBase))->impl().frame()->tree().scopedChild(propertyNameToAtomicString(propertyName))->document()->domWindow());
     78}
     79
     80static JSValue indexGetter(ExecState* exec, JSValue slotBase, unsigned index)
     81{
     82    return toJS(exec, jsCast<JSDOMWindow*>(asObject(slotBase))->impl().frame()->tree().scopedChild(index)->document()->domWindow());
     83}
     84
     85static JSValue namedItemGetter(ExecState* exec, JSValue slotBase, PropertyName propertyName)
     86{
     87    JSDOMWindowBase* thisObj = jsCast<JSDOMWindow*>(asObject(slotBase));
    8888    Document* document = thisObj->impl().frame()->document();
    8989
     
    9494    AtomicStringImpl* atomicPropertyName = findAtomicString(propertyName);
    9595    if (!atomicPropertyName || !toHTMLDocument(document)->hasWindowNamedItem(*atomicPropertyName))
    96         return JSValue::encode(jsUndefined());
     96        return jsUndefined();
    9797
    9898    if (UNLIKELY(toHTMLDocument(document)->windowNamedItemContainsMultipleElements(*atomicPropertyName))) {
    9999        RefPtr<HTMLCollection> collection = document->windowNamedItems(atomicPropertyName);
    100100        ASSERT(collection->length() > 1);
    101         return JSValue::encode(toJS(exec, thisObj->globalObject(), WTF::getPtr(collection)));
    102     }
    103 
    104     return JSValue::encode(toJS(exec, thisObj->globalObject(), toHTMLDocument(document)->windowNamedItem(*atomicPropertyName)));
     101        return toJS(exec, thisObj->globalObject(), WTF::getPtr(collection));
     102    }
     103
     104    return toJS(exec, thisObj->globalObject(), toHTMLDocument(document)->windowNamedItem(*atomicPropertyName));
    105105}
    106106
  • trunk/Source/WebCore/bindings/js/JSHTMLAllCollectionCustom.cpp

    r160133 r160204  
    101101}
    102102
    103 EncodedJSValue JSHTMLAllCollection::nameGetter(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, PropertyName propertyName)
     103JSValue JSHTMLAllCollection::nameGetter(ExecState* exec, JSValue slotBase, PropertyName propertyName)
    104104{
    105     JSHTMLAllCollection* thisObj = jsCast<JSHTMLAllCollection*>(JSValue::decode(slotBase));
    106     return JSValue::encode(getNamedItems(exec, thisObj, propertyName));
     105    JSHTMLAllCollection* thisObj = jsCast<JSHTMLAllCollection*>(asObject(slotBase));
     106    return getNamedItems(exec, thisObj, propertyName);
    107107}
    108108
  • trunk/Source/WebCore/bindings/js/JSHTMLCollectionCustom.cpp

    r160133 r160204  
    4646}
    4747
    48 EncodedJSValue JSHTMLCollection::nameGetter(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, PropertyName propertyName)
     48JSValue JSHTMLCollection::nameGetter(ExecState* exec, JSValue slotBase, PropertyName propertyName)
    4949{
    50     JSHTMLCollection* collection = jsCast<JSHTMLCollection*>(JSValue::decode(slotBase));
     50    JSHTMLCollection* collection = jsCast<JSHTMLCollection*>(asObject(slotBase));
    5151    const AtomicString& name = propertyNameToAtomicString(propertyName);
    52     return JSValue::encode(toJS(exec, collection->globalObject(), collection->impl().namedItem(name)));
     52    return toJS(exec, collection->globalObject(), collection->impl().namedItem(name));
    5353}
    5454
  • trunk/Source/WebCore/bindings/js/JSHTMLDocumentCustom.cpp

    r160133 r160204  
    5858}
    5959
    60 EncodedJSValue JSHTMLDocument::nameGetter(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, PropertyName propertyName)
     60JSValue JSHTMLDocument::nameGetter(ExecState* exec, JSValue slotBase, PropertyName propertyName)
    6161{
    62     JSHTMLDocument* thisObj = jsCast<JSHTMLDocument*>(JSValue::decode(slotBase));
     62    JSHTMLDocument* thisObj = jsCast<JSHTMLDocument*>(asObject(slotBase));
    6363    HTMLDocument& document = thisObj->impl();
    6464
    6565    AtomicStringImpl* atomicPropertyName = findAtomicString(propertyName);
    6666    if (!atomicPropertyName || !document.hasDocumentNamedItem(*atomicPropertyName))
    67         return JSValue::encode(jsUndefined());
     67        return jsUndefined();
    6868
    6969    if (UNLIKELY(document.documentNamedItemContainsMultipleElements(*atomicPropertyName))) {
    7070        RefPtr<HTMLCollection> collection = document.documentNamedItems(atomicPropertyName);
    7171        ASSERT(collection->length() > 1);
    72         return JSValue::encode(toJS(exec, thisObj->globalObject(), WTF::getPtr(collection)));
     72        return toJS(exec, thisObj->globalObject(), WTF::getPtr(collection));
    7373    }
    7474
     
    7676    if (UNLIKELY(element->hasTagName(iframeTag))) {
    7777        if (Frame* frame = toHTMLIFrameElement(element)->contentFrame())
    78             return JSValue::encode(toJS(exec, frame));
     78            return toJS(exec, frame);
    7979    }
    8080
    81     return JSValue::encode(toJS(exec, thisObj->globalObject(), element));
     81    return toJS(exec, thisObj->globalObject(), element);
    8282}
    8383
  • trunk/Source/WebCore/bindings/js/JSHTMLFormControlsCollectionCustom.cpp

    r160133 r160204  
    5858}
    5959
    60 EncodedJSValue JSHTMLFormControlsCollection::nameGetter(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, PropertyName propertyName)
     60JSValue JSHTMLFormControlsCollection::nameGetter(ExecState* exec, JSValue slotBase, PropertyName propertyName)
    6161{
    62     JSHTMLFormControlsCollection* thisObj = jsCast<JSHTMLFormControlsCollection*>(JSValue::decode(slotBase));
    63     return JSValue::encode(getNamedItems(exec, thisObj, propertyName));
     62    JSHTMLFormControlsCollection* thisObj = jsCast<JSHTMLFormControlsCollection*>(asObject(slotBase));
     63    return getNamedItems(exec, thisObj, propertyName);
    6464}
    6565
  • trunk/Source/WebCore/bindings/js/JSHTMLFormElementCustom.cpp

    r160133 r160204  
    4343}
    4444
    45 EncodedJSValue JSHTMLFormElement::nameGetter(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, PropertyName propertyName)
     45JSValue JSHTMLFormElement::nameGetter(ExecState* exec, JSValue slotBase, PropertyName propertyName)
    4646{
    47     JSHTMLFormElement* jsForm = jsCast<JSHTMLFormElement*>(JSValue::decode(slotBase));
     47    JSHTMLFormElement* jsForm = jsCast<JSHTMLFormElement*>(asObject(slotBase));
    4848    HTMLFormElement& form = jsForm->impl();
    4949
     
    5252   
    5353    if (namedItems.isEmpty())
    54         return JSValue::encode(jsUndefined());
     54        return jsUndefined();
    5555    if (namedItems.size() == 1)
    56         return JSValue::encode(toJS(exec, jsForm->globalObject(), &namedItems[0].get()));
     56        return toJS(exec, jsForm->globalObject(), &namedItems[0].get());
    5757
    5858    // FIXME: HTML5 specifies that this should be a RadioNodeList.
    59     return JSValue::encode(toJS(exec, jsForm->globalObject(), StaticElementList::adopt(namedItems).get()));
     59    return toJS(exec, jsForm->globalObject(), StaticElementList::adopt(namedItems).get());
    6060}
    6161
  • trunk/Source/WebCore/bindings/js/JSHTMLFrameSetElementCustom.cpp

    r160133 r160204  
    4848}
    4949
    50 EncodedJSValue JSHTMLFrameSetElement::nameGetter(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, PropertyName propertyName)
     50JSValue JSHTMLFrameSetElement::nameGetter(ExecState* exec, JSValue slotBase, PropertyName propertyName)
    5151{
    52     HTMLElement& element = jsCast<JSHTMLElement*>(JSValue::decode(slotBase))->impl();
     52    HTMLElement& element = jsCast<JSHTMLElement*>(asObject(slotBase))->impl();
    5353    Node* frameElement = element.children()->namedItem(propertyNameToAtomicString(propertyName));
    5454    if (Document* document = toHTMLFrameElement(frameElement)->contentDocument()) {
    5555        if (JSDOMWindowShell* window = toJSDOMWindowShell(document->frame(), currentWorld(exec)))
    56             return JSValue::encode(window);
     56            return window;
    5757    }
    58     return JSValue::encode(jsUndefined());
     58    return jsUndefined();
    5959}
    6060
  • trunk/Source/WebCore/bindings/js/JSHistoryCustom.cpp

    r160133 r160204  
    3939namespace WebCore {
    4040
    41 static EncodedJSValue nonCachingStaticBackFunctionGetter(ExecState* exec, EncodedJSValue, EncodedJSValue, PropertyName propertyName)
     41static JSValue nonCachingStaticBackFunctionGetter(ExecState* exec, JSValue, PropertyName propertyName)
    4242{
    43     return JSValue::encode(JSFunction::create(exec->vm(), exec->lexicalGlobalObject(), 0, propertyName.publicName(), jsHistoryPrototypeFunctionBack));
     43    return JSFunction::create(exec->vm(), exec->lexicalGlobalObject(), 0, propertyName.publicName(), jsHistoryPrototypeFunctionBack);
    4444}
    4545
    46 static EncodedJSValue nonCachingStaticForwardFunctionGetter(ExecState* exec, EncodedJSValue, EncodedJSValue, PropertyName propertyName)
     46static JSValue nonCachingStaticForwardFunctionGetter(ExecState* exec, JSValue, PropertyName propertyName)
    4747{
    48     return JSValue::encode(JSFunction::create(exec->vm(), exec->lexicalGlobalObject(), 0, propertyName.publicName(), jsHistoryPrototypeFunctionForward));
     48    return JSFunction::create(exec->vm(), exec->lexicalGlobalObject(), 0, propertyName.publicName(), jsHistoryPrototypeFunctionForward);
    4949}
    5050
    51 static EncodedJSValue nonCachingStaticGoFunctionGetter(ExecState* exec, EncodedJSValue, EncodedJSValue, PropertyName propertyName)
     51static JSValue nonCachingStaticGoFunctionGetter(ExecState* exec, JSValue, PropertyName propertyName)
    5252{
    53     return JSValue::encode(JSFunction::create(exec->vm(), exec->lexicalGlobalObject(), 1, propertyName.publicName(), jsHistoryPrototypeFunctionGo));
     53    return JSFunction::create(exec->vm(), exec->lexicalGlobalObject(), 1, propertyName.publicName(), jsHistoryPrototypeFunctionGo);
    5454}
    5555
  • trunk/Source/WebCore/bindings/js/JSJavaScriptCallFrameCustom.cpp

    r160133 r160204  
    107107                // First activation object is local scope, each successive activation object is closure.
    108108                if (!index)
    109                     return JSValue::decode(jsJavaScriptCallFrameLOCAL_SCOPE(exec, EncodedJSValue(), EncodedJSValue(), Identifier()));
     109                    return jsJavaScriptCallFrameLOCAL_SCOPE(exec, JSValue(), Identifier());
    110110                foundLocalScope = true;
    111111            } else if (!index)
    112                 return JSValue::decode(jsJavaScriptCallFrameCLOSURE_SCOPE(exec, EncodedJSValue(), EncodedJSValue(), Identifier()));
     112                return jsJavaScriptCallFrameCLOSURE_SCOPE(exec, JSValue(), Identifier());
    113113        }
    114114
     
    116116            // Last in the chain is global scope.
    117117            if (++iter == end)
    118                 return JSValue::decode(jsJavaScriptCallFrameGLOBAL_SCOPE(exec, EncodedJSValue(), EncodedJSValue(), Identifier()));
    119             return JSValue::decode(jsJavaScriptCallFrameWITH_SCOPE(exec, EncodedJSValue(), EncodedJSValue(), Identifier()));
     118                return jsJavaScriptCallFrameGLOBAL_SCOPE(exec, JSValue(), Identifier());
     119            return jsJavaScriptCallFrameWITH_SCOPE(exec, JSValue(), Identifier());
    120120        }
    121121
  • trunk/Source/WebCore/bindings/js/JSLocationCustom.cpp

    r160133 r160204  
    3131namespace WebCore {
    3232
    33 static EncodedJSValue nonCachingStaticReplaceFunctionGetter(ExecState* exec, EncodedJSValue, EncodedJSValue, PropertyName propertyName)
    34 {
    35     return JSValue::encode(JSFunction::create(exec->vm(), exec->lexicalGlobalObject(), 1, propertyName.publicName(), jsLocationPrototypeFunctionReplace));
    36 }
    37 
    38 static EncodedJSValue nonCachingStaticReloadFunctionGetter(ExecState* exec, EncodedJSValue, EncodedJSValue, PropertyName propertyName)
    39 {
    40     return JSValue::encode(JSFunction::create(exec->vm(), exec->lexicalGlobalObject(), 0, propertyName.publicName(), jsLocationPrototypeFunctionReload));
    41 }
    42 
    43 static EncodedJSValue nonCachingStaticAssignFunctionGetter(ExecState* exec, EncodedJSValue, EncodedJSValue, PropertyName propertyName)
    44 {
    45     return JSValue::encode(JSFunction::create(exec->vm(), exec->lexicalGlobalObject(), 1, propertyName.publicName(), jsLocationPrototypeFunctionAssign));
     33static JSValue nonCachingStaticReplaceFunctionGetter(ExecState* exec, JSValue, PropertyName propertyName)
     34{
     35    return JSFunction::create(exec->vm(), exec->lexicalGlobalObject(), 1, propertyName.publicName(), jsLocationPrototypeFunctionReplace);
     36}
     37
     38static JSValue nonCachingStaticReloadFunctionGetter(ExecState* exec, JSValue, PropertyName propertyName)
     39{
     40    return JSFunction::create(exec->vm(), exec->lexicalGlobalObject(), 0, propertyName.publicName(), jsLocationPrototypeFunctionReload);
     41}
     42
     43static JSValue nonCachingStaticAssignFunctionGetter(ExecState* exec, JSValue, PropertyName propertyName)
     44{
     45    return JSFunction::create(exec->vm(), exec->lexicalGlobalObject(), 1, propertyName.publicName(), jsLocationPrototypeFunctionAssign);
    4646}
    4747
  • trunk/Source/WebCore/bindings/js/JSNamedNodeMapCustom.cpp

    r160133 r160204  
    4141}
    4242
    43 EncodedJSValue JSNamedNodeMap::nameGetter(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, PropertyName propertyName)
     43JSValue JSNamedNodeMap::nameGetter(ExecState* exec, JSValue slotBase, PropertyName propertyName)
    4444{
    45     JSNamedNodeMap* thisObj = jsCast<JSNamedNodeMap*>(JSValue::decode(slotBase));
    46     return JSValue::encode(toJS(exec, thisObj->globalObject(), thisObj->impl().getNamedItem(propertyNameToAtomicString(propertyName))));
     45    JSNamedNodeMap* thisObj = jsCast<JSNamedNodeMap*>(asObject(slotBase));
     46    return toJS(exec, thisObj->globalObject(), thisObj->impl().getNamedItem(propertyNameToAtomicString(propertyName)));
    4747}
    4848
  • trunk/Source/WebCore/bindings/js/JSNodeListCustom.cpp

    r160133 r160204  
    5757}
    5858
    59 EncodedJSValue JSNodeList::nameGetter(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, PropertyName propertyName)
     59JSValue JSNodeList::nameGetter(ExecState* exec, JSValue slotBase, PropertyName propertyName)
    6060{
    61     JSNodeList* thisObj = jsCast<JSNodeList*>(JSValue::decode(slotBase));
    62     return JSValue::encode(toJS(exec, thisObj->globalObject(), thisObj->impl().namedItem(propertyNameToAtomicString(propertyName))));
     61    JSNodeList* thisObj = jsCast<JSNodeList*>(asObject(slotBase));
     62    return toJS(exec, thisObj->globalObject(), thisObj->impl().namedItem(propertyNameToAtomicString(propertyName)));
    6363}
    6464
  • trunk/Source/WebCore/bindings/js/JSPluginElementFunctions.cpp

    r160133 r160204  
    101101}
    102102   
    103 EncodedJSValue pluginElementPropertyGetter(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, PropertyName propertyName)
     103JSValue pluginElementPropertyGetter(ExecState* exec, JSValue slotBase, PropertyName propertyName)
    104104{
    105     JSHTMLElement* element = jsCast<JSHTMLElement*>(JSValue::decode(slotBase));
     105    JSHTMLElement* element = jsCast<JSHTMLElement*>(asObject(slotBase));
    106106    JSObject* scriptObject = pluginScriptObject(exec, element);
    107107    if (!scriptObject)
    108         return JSValue::encode(jsUndefined());
     108        return jsUndefined();
    109109   
    110     return JSValue::encode(scriptObject->get(exec, propertyName));
     110    return scriptObject->get(exec, propertyName);
    111111}
    112112
  • trunk/Source/WebCore/bindings/js/JSPluginElementFunctions.h

    r160133 r160204  
    3939    JSC::JSObject* pluginScriptObject(JSC::ExecState*, JSHTMLElement*);
    4040
    41     JSC::EncodedJSValue pluginElementPropertyGetter(JSC::ExecState*, JSC::EncodedJSValue, JSC::EncodedJSValue, JSC::PropertyName);
     41    JSC::JSValue pluginElementPropertyGetter(JSC::ExecState*, JSC::JSValue, JSC::PropertyName);
    4242    bool pluginElementCustomGetOwnPropertySlot(JSC::ExecState*, JSC::PropertyName, JSC::PropertySlot&, JSHTMLElement*);
    4343    bool pluginElementCustomPut(JSC::ExecState*, JSC::PropertyName, JSC::JSValue, JSHTMLElement*, JSC::PutPropertySlot&);
  • trunk/Source/WebCore/bindings/js/JSRTCStatsResponseCustom.cpp

    r160133 r160204  
    4141}
    4242
    43 EncodedJSValue JSRTCStatsResponse::nameGetter(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, PropertyName propertyName)
     43JSValue JSRTCStatsResponse::nameGetter(ExecState* exec, JSValue slotBase, PropertyName propertyName)
    4444{
    45     JSRTCStatsResponse* thisObj = jsCast<JSRTCStatsResponse*>(JSValue::decode(slotBase));
    46     return JSValue::encode(toJS(exec, thisObj->globalObject(), thisObj->impl().namedItem(propertyNameToAtomicString(propertyName))));
     45    JSRTCStatsResponse* thisObj = jsCast<JSRTCStatsResponse*>(asObject(slotBase));
     46    return toJS(exec, thisObj->globalObject(), thisObj->impl().namedItem(propertyNameToAtomicString(propertyName)));
    4747}
    4848
  • trunk/Source/WebCore/bindings/js/JSStorageCustom.cpp

    r160133 r160204  
    4343}
    4444
    45 EncodedJSValue JSStorage::nameGetter(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, PropertyName propertyName)
     45JSValue JSStorage::nameGetter(ExecState* exec, JSValue slotBase, PropertyName propertyName)
    4646{
    47     JSStorage* thisObj = jsCast<JSStorage*>(JSValue::decode(slotBase));
     47    JSStorage* thisObj = jsCast<JSStorage*>(asObject(slotBase));
    4848       
    49     JSValue prototype = asObject(JSValue::decode(slotBase))->prototype();
     49    JSValue prototype = asObject(slotBase)->prototype();
    5050    if (prototype.isObject() && asObject(prototype)->hasProperty(exec, propertyName))
    51         return JSValue::encode(asObject(prototype)->get(exec, propertyName));
     51        return asObject(prototype)->get(exec, propertyName);
    5252 
    5353    ExceptionCode ec = 0;
    5454    JSValue result = jsStringOrNull(exec, thisObj->impl().getItem(propertyNameToString(propertyName), ec));
    5555    setDOMException(exec, ec);
    56     return JSValue::encode(result);
     56    return result;
    5757}
    5858
  • trunk/Source/WebCore/bindings/js/JSStyleSheetListCustom.cpp

    r160133 r160204  
    4141}
    4242
    43 EncodedJSValue JSStyleSheetList::nameGetter(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, PropertyName propertyName)
     43JSValue JSStyleSheetList::nameGetter(ExecState* exec, JSValue slotBase, PropertyName propertyName)
    4444{
    45     JSStyleSheetList* thisObj = jsCast<JSStyleSheetList*>(JSValue::decode(slotBase));
     45    JSStyleSheetList* thisObj = jsCast<JSStyleSheetList*>(asObject(slotBase));
    4646    HTMLStyleElement* element = thisObj->impl().getNamedItem(propertyNameToString(propertyName));
    4747    ASSERT(element);
    48     return JSValue::encode(toJS(exec, thisObj->globalObject(), element->sheet()));
     48    return toJS(exec, thisObj->globalObject(), element->sheet());
    4949}
    5050
  • trunk/Source/WebCore/bindings/scripts/CodeGeneratorJS.pm

    r160133 r160204  
    894894            push(@headerContent, "    JSC::JSValue getByIndex(JSC::ExecState*, unsigned index);\n");
    895895        } else {
    896             push(@headerContent, "    static JSC::EncodedJSValue indexGetter(JSC::ExecState*, JSC::EncodedJSValue, JSC::EncodedJSValue, unsigned);\n");
     896            push(@headerContent, "    static JSC::JSValue indexGetter(JSC::ExecState*, JSC::JSValue, unsigned);\n");
    897897        }
    898898    }
     
    906906        push(@headerContent, "private:\n");
    907907        push(@headerContent, "    static bool canGetItemsForName(JSC::ExecState*, $interfaceName*, JSC::PropertyName);\n");
    908         push(@headerContent, "    static JSC::EncodedJSValue nameGetter(JSC::ExecState*, JSC::EncodedJSValue, JSC::EncodedJSValue, JSC::PropertyName);\n");
     908        push(@headerContent, "    static JSC::JSValue nameGetter(JSC::ExecState*, JSC::JSValue, JSC::PropertyName);\n");
    909909    }
    910910
     
    10421042            push(@headerContent, "#if ${conditionalString}\n") if $conditionalString;
    10431043            my $getter = GetAttributeGetterName($interfaceName, $className, $attribute);
    1044             push(@headerContent, "JSC::EncodedJSValue ${getter}(JSC::ExecState*, JSC::EncodedJSValue, JSC::EncodedJSValue, JSC::PropertyName);\n");
     1044            push(@headerContent, "JSC::JSValue ${getter}(JSC::ExecState*, JSC::JSValue, JSC::PropertyName);\n");
    10451045            if (!IsReadonly($attribute)) {
    10461046                my $setter = GetAttributeSetterName($interfaceName, $className, $attribute);
     
    10521052        if (!$interface->extendedAttributes->{"NoInterfaceObject"}) {
    10531053            my $getter = "js" . $interfaceName . "Constructor";
    1054             push(@headerContent, "JSC::EncodedJSValue ${getter}(JSC::ExecState*, JSC::EncodedJSValue, JSC::EncodedJSValue, JSC::PropertyName);\n");
     1054            push(@headerContent, "JSC::JSValue ${getter}(JSC::ExecState*, JSC::JSValue, JSC::PropertyName);\n");
    10551055        }
    10561056
     
    10671067            push(@headerContent, "#if ${conditionalString}\n") if $conditionalString;
    10681068            my $getter = "js" . $interfaceName . $codeGenerator->WK_ucfirst($constant->name);
    1069             push(@headerContent, "JSC::EncodedJSValue ${getter}(JSC::ExecState*, JSC::EncodedJSValue, JSC::EncodedJSValue, JSC::PropertyName);\n");
     1069            push(@headerContent, "JSC::JSValue ${getter}(JSC::ExecState*, JSC::JSValue, JSC::PropertyName);\n");
    10701070            push(@headerContent, "#endif\n") if $conditionalString;
    10711071        }
     
    18761876                push(@implContent, "#if ${attributeConditionalString}\n") if $attributeConditionalString;
    18771877
    1878                 push(@implContent, "EncodedJSValue ${getFunctionName}(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, PropertyName)\n");
     1878                push(@implContent, "JSValue ${getFunctionName}(ExecState* exec, JSValue slotBase, PropertyName)\n");
    18791879                push(@implContent, "{\n");
    18801880
    18811881                if (!$attribute->isStatic || $attribute->signature->type =~ /Constructor$/) {
    1882                     push(@implContent, "    ${className}* castedThis = jsDynamicCast<$className*>(JSValue::decode(slotBase));\n");
     1882                    push(@implContent, "    ${className}* castedThis = jsCast<$className*>(asObject(slotBase));\n");
    18831883                } else {
    18841884                    push(@implContent, "    UNUSED_PARAM(slotBase);\n");
     
    18911891                        my $enable_function = GetRuntimeEnableFunctionName($attribute->signature);
    18921892                        push(@implContent, "    if (!${enable_function}())\n");
    1893                         push(@implContent, "        return JSValue::encode(jsUndefined());\n");
     1893                        push(@implContent, "        return jsUndefined();\n");
    18941894                    } elsif ($attribute->signature->extendedAttributes->{"EnabledBySetting"}) {
    18951895                        AddToImplIncludes("Frame.h");
     
    18971897                        my $enable_function = ToMethodName($attribute->signature->extendedAttributes->{"EnabledBySetting"}) . "Enabled";
    18981898                        push(@implContent, "    if (!castedThis->impl().frame())\n");
    1899                         push(@implContent, "        return JSValue::encode(jsUndefined());\n");
     1899                        push(@implContent, "        return jsUndefined();\n");
    19001900                        push(@implContent, "    Settings& settings = castedThis->impl().frame()->settings();\n");
    19011901                        push(@implContent, "    if (!settings.$enable_function())\n");
    1902                         push(@implContent, "        return JSValue::encode(jsUndefined());\n");
     1902                        push(@implContent, "        return jsUndefined();\n");
    19031903                    }
    19041904                }
     
    19121912                    !$attribute->signature->extendedAttributes->{"DoNotCheckSecurityOnGetter"}) {
    19131913                    push(@implContent, "    if (!BindingSecurity::shouldAllowAccessToDOMWindow(exec, castedThis->impl()))\n");
    1914                     push(@implContent, "        return JSValue::encode(jsUndefined());\n");
     1914                    push(@implContent, "        return jsUndefined();\n");
    19151915                }
    19161916
    19171917                if (HasCustomGetter($attribute->signature->extendedAttributes)) {
    1918                     push(@implContent, "    return JSValue::encode(castedThis->$implGetterFunctionName(exec));\n");
     1918                    push(@implContent, "    return castedThis->$implGetterFunctionName(exec);\n");
    19191919                } elsif ($attribute->signature->extendedAttributes->{"CheckSecurityForNode"}) {
    19201920                    $implIncludes{"JSDOMBinding.h"} = 1;
    19211921                    push(@implContent, "    $interfaceName& impl = castedThis->impl();\n");
    1922                     push(@implContent, "    return JSValue::encode(shouldAllowAccessToNode(exec, impl." . $attribute->signature->name . "()) ? " . NativeToJSValue($attribute->signature, 0, $interfaceName, "impl.$implGetterFunctionName()", "castedThis") . " : jsNull());\n");
     1922                    push(@implContent, "    return shouldAllowAccessToNode(exec, impl." . $attribute->signature->name . "()) ? " . NativeToJSValue($attribute->signature, 0, $interfaceName, "impl.$implGetterFunctionName()", "castedThis") . " : jsNull();\n");
    19231923                } elsif ($type eq "EventListener") {
    19241924                    $implIncludes{"EventListener.h"} = 1;
     
    19321932                        push(@implContent, "            if (JSObject* jsFunction = jsListener->jsFunction(impl.scriptExecutionContext()))\n");
    19331933                    }
    1934                     push(@implContent, "                return JSValue::encode(jsFunction);\n");
     1934                    push(@implContent, "                return jsFunction;\n");
    19351935                    push(@implContent, "        }\n");
    19361936                    push(@implContent, "    }\n");
    1937                     push(@implContent, "    return JSValue::encode(jsNull());\n");
     1937                    push(@implContent, "    return jsNull();\n");
    19381938                } elsif ($attribute->signature->type =~ /Constructor$/) {
    19391939                    my $constructorType = $attribute->signature->type;
     
    19441944                        my $named = ($constructorType =~ /Named$/) ? "Named" : "";
    19451945                        $constructorType =~ s/Named$//;
    1946                         push(@implContent, "    return JSValue::encode(JS" . $constructorType . "::get${named}Constructor(exec->vm(), castedThis));\n");
     1946                        push(@implContent, "    return JS" . $constructorType . "::get${named}Constructor(exec->vm(), castedThis);\n");
    19471947                    } else {
    19481948                       AddToImplIncludes("JS" . $constructorType . ".h", $attribute->signature->extendedAttributes->{"Conditional"});
    1949                        push(@implContent, "    return JSValue::encode(JS" . $constructorType . "::getConstructor(exec->vm(), castedThis->globalObject()));\n");
     1949                       push(@implContent, "    return JS" . $constructorType . "::getConstructor(exec->vm(), castedThis->globalObject());\n");
    19501950                    }
    19511951                } elsif (!$attribute->signature->extendedAttributes->{"GetterRaisesException"}) {
     
    19581958                        $currentCachedAttribute++;
    19591959                        push(@implContent, "    if (JSValue cachedValue = castedThis->m_" . $attribute->signature->name . ".get())\n");
    1960                         push(@implContent, "        return JSValue::encode(cachedValue);\n");
     1960                        push(@implContent, "        return cachedValue;\n");
    19611961                    }
    19621962
    1963                     my @callWithArgs = GenerateCallWith($attribute->signature->extendedAttributes->{"CallWith"}, \@implContent, "JSValue::encode(jsUndefined())");
     1963                    my @callWithArgs = GenerateCallWith($attribute->signature->extendedAttributes->{"CallWith"}, \@implContent, "jsUndefined()");
    19641964
    19651965                    if ($svgListPropertyType) {
     
    19991999                        if ($isNullable) {
    20002000                            push(@implContent, "    if (isNull)\n");
    2001                             push(@implContent, "        return JSValue::encode(jsNull());\n");
     2001                            push(@implContent, "        return jsNull();\n");
    20022002                        }
    20032003                    }
    20042004
    20052005                    push(@implContent, "    castedThis->m_" . $attribute->signature->name . ".set(exec->vm(), castedThis, result);\n") if ($attribute->signature->extendedAttributes->{"CachedAttribute"});
    2006                     push(@implContent, "    return JSValue::encode(result);\n");
     2006                    push(@implContent, "    return result;\n");
    20072007
    20082008                } else {
     
    20152015                    }
    20162016
    2017                     unshift(@arguments, GenerateCallWith($attribute->signature->extendedAttributes->{"CallWith"}, \@implContent, "JSValue::encode(jsUndefined())"));
     2017                    unshift(@arguments, GenerateCallWith($attribute->signature->extendedAttributes->{"CallWith"}, \@implContent, "jsUndefined()"));
    20182018
    20192019                    if ($svgPropertyOrListPropertyType) {
     
    20272027                    if ($isNullable) {
    20282028                        push(@implContent, "    if (isNull)\n");
    2029                         push(@implContent, "        return JSValue::encode(jsNull());\n");
     2029                        push(@implContent, "        return jsNull();\n");
    20302030                    }
    20312031
    20322032                    push(@implContent, "    setDOMException(exec, ec);\n");
    2033                     push(@implContent, "    return JSValue::encode(result);\n");
     2033                    push(@implContent, "    return result;\n");
    20342034                }
    20352035
     
    20442044                my $constructorFunctionName = "js" . $interfaceName . "Constructor";
    20452045
    2046                 push(@implContent, "EncodedJSValue ${constructorFunctionName}(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, PropertyName)\n");
     2046                push(@implContent, "JSValue ${constructorFunctionName}(ExecState* exec, JSValue slotBase, PropertyName)\n");
    20472047                push(@implContent, "{\n");
    2048                 push(@implContent, "    ${className}* domObject = jsDynamicCast<$className*>(JSValue::decode(slotBase));\n");
     2048                push(@implContent, "    ${className}* domObject = jsCast<$className*>(asObject(slotBase));\n");
    20492049
    20502050                if ($interface->extendedAttributes->{"CheckSecurity"}) {
    20512051                    push(@implContent, "    if (!BindingSecurity::shouldAllowAccessToDOMWindow(exec, domObject->impl()))\n");
    2052                     push(@implContent, "        return JSValue::encode(jsUndefined());\n");
     2052                    push(@implContent, "        return jsUndefined();\n");
    20532053                }
    20542054
    2055                 push(@implContent, "    return JSValue::encode(${className}::getConstructor(exec->vm(), domObject->globalObject()));\n");
     2055                push(@implContent, "    return ${className}::getConstructor(exec->vm(), domObject->globalObject());\n");
    20562056                push(@implContent, "}\n\n");
    20572057            }
     
    23852385                } else {
    23862386                    push(@implContent, "    JSValue thisValue = exec->hostThisValue();\n");
    2387                     push(@implContent, "    $className* castedThis = jsDynamicCast<$className*>(thisValue);\n");
    2388                     push(@implContent, "    if (!castedThis)\n");
     2387                    push(@implContent, "    if (!thisValue.inherits(${className}::info()))\n");
    23892388                    push(@implContent, "        return throwVMTypeError(exec);\n");
     2389                    push(@implContent, "    $className* castedThis = jsCast<$className*>(asObject(thisValue));\n");
    23902390                }
    23912391
     
    24852485
    24862486            # FIXME: this casts into int to match our previous behavior which turned 0xFFFFFFFF in -1 for NodeFilter.SHOW_ALL
    2487             push(@implContent, "EncodedJSValue ${getter}(ExecState* exec, EncodedJSValue, EncodedJSValue, PropertyName)\n");
     2487            push(@implContent, "JSValue ${getter}(ExecState* exec, JSValue, PropertyName)\n");
    24882488            push(@implContent, "{\n");
    24892489            if ($constant->type eq "DOMString") {
    2490                 push(@implContent, "    return JSValue::encode(jsStringOrNull(exec, String(" . $constant->value . ")));\n");
     2490                push(@implContent, "    return jsStringOrNull(exec, String(" . $constant->value . "));\n");
    24912491            } else {
    24922492                push(@implContent, "    UNUSED_PARAM(exec);\n");
    2493                 push(@implContent, "    return JSValue::encode(jsNumber(static_cast<int>(" . $constant->value . ")));\n");
     2493                push(@implContent, "    return jsNumber(static_cast<int>(" . $constant->value . "));\n");
    24942494            }
    24952495            push(@implContent, "}\n\n");
     
    24992499
    25002500    if ($indexedGetterFunction && !$hasNumericIndexedGetter) {
    2501         push(@implContent, "\nEncodedJSValue ${className}::indexGetter(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, unsigned index)\n");
     2501        push(@implContent, "\nJSValue ${className}::indexGetter(ExecState* exec, JSValue slotBase, unsigned index)\n");
    25022502        push(@implContent, "{\n");
    2503         push(@implContent, "    ${className}* thisObj = jsCast<$className*>(JSValue::decode(slotBase));\n");
     2503        push(@implContent, "    ${className}* thisObj = jsCast<$className*>(asObject(slotBase));\n");
    25042504        push(@implContent, "    ASSERT_GC_OBJECT_INHERITS(thisObj, info());\n");
    25052505        if ($indexedGetterFunction->signature->type eq "DOMString") {
    25062506            $implIncludes{"URL.h"} = 1;
    2507             push(@implContent, "    return JSValue::encode(jsStringOrUndefined(exec, thisObj->impl().item(index)));\n");
     2507            push(@implContent, "    return jsStringOrUndefined(exec, thisObj->impl().item(index));\n");
    25082508        } else {
    2509             push(@implContent, "    return JSValue::encode(toJS(exec, thisObj->globalObject(), thisObj->impl().item(index)));\n");
     2509            push(@implContent, "    return toJS(exec, thisObj->globalObject(), thisObj->impl().item(index));\n");
    25102510        }
    25112511        push(@implContent, "}\n\n");
     
    25382538            push(@implContent, "    return collection->hasNamedItem(propertyNameToAtomicString(propertyName));\n");
    25392539            push(@implContent, "}\n\n");
    2540             push(@implContent, "EncodedJSValue ${className}::nameGetter(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, PropertyName propertyName)\n");
     2540            push(@implContent, "JSValue ${className}::nameGetter(ExecState* exec, JSValue slotBase, PropertyName propertyName)\n");
    25412541            push(@implContent, "{\n");
    2542             push(@implContent, "    ${className}* thisObj = jsCast<$className*>(JSValue::decode(slotBase));\n");
    2543             push(@implContent, "    return JSValue::encode(toJS(exec, thisObj->globalObject(), thisObj->impl().namedItem(propertyNameToAtomicString(propertyName))));\n");
     2542            push(@implContent, "    ${className}* thisObj = jsCast<$className*>(asObject(slotBase));\n");
     2543            push(@implContent, "    return toJS(exec, thisObj->globalObject(), thisObj->impl().namedItem(propertyNameToAtomicString(propertyName)));\n");
    25442544            push(@implContent, "}\n\n");
    25452545        }
     
    27322732        push(@implContent, "$implType* to${interfaceName}(JSC::JSValue value)\n");
    27332733        push(@implContent, "{\n");
    2734         push(@implContent, "    return value.inherits(${className}::info()) ? &jsCast<$className*>(value)->impl() : 0");
     2734        push(@implContent, "    return value.inherits(${className}::info()) ? &jsCast<$className*>(asObject(value))->impl() : 0");
    27352735        push(@implContent, ";\n}\n");
    27362736    }
     
    28722872                if ($function->isStatic) {
    28732873                    AddToImplIncludes("CallbackFunction.h");
    2874                     push(@$outputArray, "        $name = createFunctionOnlyCallback<${callbackClassName}>(exec, jsCast<JSDOMGlobalObject*>(exec->lexicalGlobalObject()), exec->uncheckedArgument($argsIndex));\n");
     2874                    push(@$outputArray, "        $name = createFunctionOnlyCallback<${callbackClassName}>(exec, static_cast<JSDOMGlobalObject*>(exec->lexicalGlobalObject()), exec->uncheckedArgument($argsIndex));\n");
    28752875                } else {
    28762876                    push(@$outputArray, "        $name = ${callbackClassName}::create(asObject(exec->uncheckedArgument($argsIndex)), castedThis->globalObject());\n");
     
    28822882                if ($function->isStatic) {
    28832883                    AddToImplIncludes("CallbackFunction.h");
    2884                     push(@$outputArray, "    RefPtr<$argType> $name = createFunctionOnlyCallback<${callbackClassName}>(exec, jsCast<JSDOMGlobalObject*>(exec->lexicalGlobalObject()), exec->uncheckedArgument($argsIndex));\n");
     2884                    push(@$outputArray, "    RefPtr<$argType> $name = createFunctionOnlyCallback<${callbackClassName}>(exec, static_cast<JSDOMGlobalObject*>(exec->lexicalGlobalObject()), exec->uncheckedArgument($argsIndex));\n");
    28852885                } else {
    28862886                    push(@$outputArray, "    RefPtr<$argType> $name = ${callbackClassName}::create(asObject(exec->uncheckedArgument($argsIndex)), castedThis->globalObject());\n");
  • trunk/Source/WebCore/bridge/runtime_array.cpp

    r160133 r160204  
    6161}
    6262
    63 EncodedJSValue RuntimeArray::lengthGetter(ExecState*, EncodedJSValue slotBase, EncodedJSValue, PropertyName)
     63JSValue RuntimeArray::lengthGetter(ExecState*, JSValue slotBase, PropertyName)
    6464{
    65     RuntimeArray* thisObj = jsCast<RuntimeArray*>(JSValue::decode(slotBase));
    66     return JSValue::encode(jsNumber(thisObj->getLength()));
     65    RuntimeArray* thisObj = static_cast<RuntimeArray*>(asObject(slotBase));
     66    return jsNumber(thisObj->getLength());
    6767}
    6868
    69 EncodedJSValue RuntimeArray::indexGetter(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, unsigned index)
     69JSValue RuntimeArray::indexGetter(ExecState* exec, JSValue slotBase, unsigned index)
    7070{
    71     RuntimeArray* thisObj = jsCast<RuntimeArray*>(JSValue::decode(slotBase));
    72     return JSValue::encode(thisObj->getConcreteArray()->valueAt(exec, index));
     71    RuntimeArray* thisObj = static_cast<RuntimeArray*>(asObject(slotBase));
     72    return thisObj->getConcreteArray()->valueAt(exec, index);
    7373}
    7474
  • trunk/Source/WebCore/bridge/runtime_array.h

    r160133 r160204  
    8585private:
    8686    RuntimeArray(ExecState*, Structure*);
    87     static EncodedJSValue lengthGetter(ExecState*, EncodedJSValue, EncodedJSValue, PropertyName);
    88     static EncodedJSValue indexGetter(ExecState*, EncodedJSValue, EncodedJSValue, unsigned);
     87    static JSValue lengthGetter(ExecState*, JSValue, PropertyName);
     88    static JSValue indexGetter(ExecState*, JSValue, unsigned);
    8989
    9090    BindingsArray* m_array;
  • trunk/Source/WebCore/bridge/runtime_method.cpp

    r160133 r160204  
    5555}
    5656
    57 EncodedJSValue RuntimeMethod::lengthGetter(ExecState*, EncodedJSValue slotBase, EncodedJSValue, PropertyName)
     57JSValue RuntimeMethod::lengthGetter(ExecState*, JSValue slotBase, PropertyName)
    5858{
    59     RuntimeMethod* thisObj = jsCast<RuntimeMethod*>(JSValue::decode(slotBase));
     59    RuntimeMethod* thisObj = static_cast<RuntimeMethod*>(asObject(slotBase));
    6060
    61     return JSValue::encode(jsNumber(thisObj->m_method->numParameters()));
     61    return jsNumber(thisObj->m_method->numParameters());
    6262}
    6363
  • trunk/Source/WebCore/bridge/runtime_method.h

    r160133 r160204  
    6868
    6969private:
    70     static EncodedJSValue lengthGetter(ExecState*, EncodedJSValue, EncodedJSValue, PropertyName);
     70    static JSValue lengthGetter(ExecState*, JSValue, PropertyName);
    7171
    7272    Bindings::Method* m_method;
  • trunk/Source/WebCore/bridge/runtime_object.cpp

    r160133 r160204  
    6363}
    6464
    65 EncodedJSValue RuntimeObject::fallbackObjectGetter(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, PropertyName propertyName)
    66 {
    67     RuntimeObject* thisObj = jsCast<RuntimeObject*>(JSValue::decode(slotBase));
     65JSValue RuntimeObject::fallbackObjectGetter(ExecState* exec, JSValue slotBase, PropertyName propertyName)
     66{
     67    RuntimeObject* thisObj = static_cast<RuntimeObject*>(asObject(slotBase));
    6868    RefPtr<Instance> instance = thisObj->m_instance;
    6969
    7070    if (!instance)
    71         return JSValue::encode(throwInvalidAccessError(exec));
     71        return throwInvalidAccessError(exec);
    7272   
    7373    instance->begin();
     
    7878    instance->end();
    7979           
    80     return JSValue::encode(result);
    81 }
    82 
    83 EncodedJSValue RuntimeObject::fieldGetter(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, PropertyName propertyName)
     80    return result;
     81}
     82
     83JSValue RuntimeObject::fieldGetter(ExecState* exec, JSValue slotBase, PropertyName propertyName)
    8484{   
    85     RuntimeObject* thisObj = jsCast<RuntimeObject*>(JSValue::decode(slotBase));
     85    RuntimeObject* thisObj = static_cast<RuntimeObject*>(asObject(slotBase));
    8686    RefPtr<Instance> instance = thisObj->m_instance;
    8787
    8888    if (!instance)
    89         return JSValue::encode(throwInvalidAccessError(exec));
     89        return throwInvalidAccessError(exec);
    9090   
    9191    instance->begin();
     
    9797    instance->end();
    9898           
    99     return JSValue::encode(result);
    100 }
    101 
    102 EncodedJSValue RuntimeObject::methodGetter(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, PropertyName propertyName)
    103 {
    104     RuntimeObject* thisObj = jsCast<RuntimeObject*>(JSValue::decode(slotBase));
     99    return result;
     100}
     101
     102JSValue RuntimeObject::methodGetter(ExecState* exec, JSValue slotBase, PropertyName propertyName)
     103{
     104    RuntimeObject* thisObj = static_cast<RuntimeObject*>(asObject(slotBase));
    105105    RefPtr<Instance> instance = thisObj->m_instance;
    106106
    107107    if (!instance)
    108         return JSValue::encode(throwInvalidAccessError(exec));
     108        return throwInvalidAccessError(exec);
    109109   
    110110    instance->begin();
     
    114114    instance->end();
    115115           
    116     return JSValue::encode(method);
     116    return method;
    117117}
    118118
  • trunk/Source/WebCore/bridge/runtime_object.h

    r160133 r160204  
    7979
    8080private:
    81     static EncodedJSValue fallbackObjectGetter(ExecState*, EncodedJSValue, EncodedJSValue, PropertyName);
    82     static EncodedJSValue fieldGetter(ExecState*, EncodedJSValue, EncodedJSValue, PropertyName);
    83     static EncodedJSValue methodGetter(ExecState*, EncodedJSValue, EncodedJSValue, PropertyName);
     81    static JSValue fallbackObjectGetter(ExecState*, JSValue, PropertyName);
     82    static JSValue fieldGetter(ExecState*, JSValue, PropertyName);
     83    static JSValue methodGetter(ExecState*, JSValue, PropertyName);
    8484
    8585    RefPtr<Instance> m_instance;
  • trunk/Source/WebKit2/ChangeLog

    r160197 r160204  
     12013-12-05  Commit Queue  <commit-queue@webkit.org>
     2
     3        Unreviewed, rolling out r160133.
     4        http://trac.webkit.org/changeset/160133
     5        https://bugs.webkit.org/show_bug.cgi?id=125325
     6
     7        broke bindings tests on all the bots (Requested by thorton on
     8        #webkit).
     9
     10        * WebProcess/Plugins/Netscape/JSNPMethod.cpp:
     11        (WebKit::callMethod):
     12        * WebProcess/Plugins/Netscape/JSNPObject.cpp:
     13        (WebKit::callNPJSObject):
     14        (WebKit::constructWithConstructor):
     15        (WebKit::JSNPObject::propertyGetter):
     16        (WebKit::JSNPObject::methodGetter):
     17        * WebProcess/Plugins/Netscape/JSNPObject.h:
     18        * WebProcess/Plugins/Netscape/NPRuntimeObjectMap.cpp:
     19        (WebKit::NPRuntimeObjectMap::getOrCreateNPObject):
     20        (WebKit::NPRuntimeObjectMap::finalize):
     21        * WebProcess/WebPage/WebFrame.cpp:
     22        (WebKit::WebFrame::counterValue):
     23
    1242013-12-05  Chris Fleizach  <cfleizach@apple.com>
    225
  • trunk/Source/WebKit2/WebProcess/Plugins/Netscape/JSNPMethod.cpp

    r160133 r160204  
    6060static EncodedJSValue JSC_HOST_CALL callMethod(ExecState* exec)
    6161{
    62     JSNPMethod* jsNPMethod = jsCast<JSNPMethod*>(exec->callee());
     62    JSNPMethod* jsNPMethod = static_cast<JSNPMethod*>(exec->callee());
    6363
    6464    JSValue thisValue = exec->hostThisValue();
     
    6666    // Check if we're calling a method on the plug-in script object.
    6767    if (thisValue.inherits(JSHTMLElement::info())) {
    68         JSHTMLElement* element = jsCast<JSHTMLElement*>(asObject(thisValue));
     68        JSHTMLElement* element = static_cast<JSHTMLElement*>(asObject(thisValue));
    6969
    7070        // Try to get the script object from the element
     
    7474
    7575    if (thisValue.inherits(JSNPObject::info())) {
    76         JSNPObject* jsNPObject = jsCast<JSNPObject*>(asObject(thisValue));
     76        JSNPObject* jsNPObject = static_cast<JSNPObject*>(asObject(thisValue));
    7777
    7878        return JSValue::encode(jsNPObject->callMethod(exec, jsNPMethod->npIdentifier()));
  • trunk/Source/WebKit2/WebProcess/Plugins/Netscape/JSNPObject.cpp

    r160133 r160204  
    226226    ASSERT(object->inherits(JSNPObject::info()));
    227227
    228     return JSValue::encode(jsCast<JSNPObject*>(object)->callObject(exec));
     228    return JSValue::encode(static_cast<JSNPObject*>(object)->callObject(exec));
    229229}
    230230
     
    245245    ASSERT(constructor->inherits(JSNPObject::info()));
    246246
    247     return JSValue::encode(jsCast<JSNPObject*>(constructor)->callConstructor(exec));
     247    return JSValue::encode(static_cast<JSNPObject*>(constructor)->callConstructor(exec));
    248248}
    249249
     
    418418}
    419419
    420 EncodedJSValue JSNPObject::propertyGetter(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, PropertyName propertyName)
    421 {
    422     JSNPObject* thisObj = jsCast<JSNPObject*>(JSValue::decode(slotBase));
     420JSValue JSNPObject::propertyGetter(ExecState* exec, JSValue slotBase, PropertyName propertyName)
     421{
     422    JSNPObject* thisObj = static_cast<JSNPObject*>(asObject(slotBase));
    423423    ASSERT_GC_OBJECT_INHERITS(thisObj, info());
    424424   
    425425    if (!thisObj->m_npObject)
    426         return JSValue::encode(throwInvalidAccessError(exec));
     426        return throwInvalidAccessError(exec);
    427427
    428428    if (!thisObj->m_npObject->_class->getProperty)
    429         return JSValue::encode(jsUndefined());
     429        return jsUndefined();
    430430
    431431    NPVariant result;
     
    447447
    448448    if (!returnValue)
    449         return JSValue::encode(jsUndefined());
     449        return jsUndefined();
    450450
    451451    JSValue propertyValue = thisObj->m_objectMap->convertNPVariantToJSValue(exec, thisObj->globalObject(), result);
    452452    releaseNPVariantValue(&result);
    453     return JSValue::encode(propertyValue);
    454 }
    455 
    456 EncodedJSValue JSNPObject::methodGetter(ExecState* exec, EncodedJSValue slotBase, EncodedJSValue, PropertyName propertyName)
    457 {
    458     JSNPObject* thisObj = jsCast<JSNPObject*>(JSValue::decode(slotBase));
     453    return propertyValue;
     454}
     455
     456JSValue JSNPObject::methodGetter(ExecState* exec, JSValue slotBase, PropertyName propertyName)
     457{
     458    JSNPObject* thisObj = static_cast<JSNPObject*>(asObject(slotBase));
    459459    ASSERT_GC_OBJECT_INHERITS(thisObj, info());
    460460   
    461461    if (!thisObj->m_npObject)
    462         return JSValue::encode(throwInvalidAccessError(exec));
     462        return throwInvalidAccessError(exec);
    463463
    464464    NPIdentifier npIdentifier = npIdentifierFromIdentifier(propertyName);
    465     return JSValue::encode(JSNPMethod::create(exec, thisObj->globalObject(), propertyName.publicName(), npIdentifier));
     465    return JSNPMethod::create(exec, thisObj->globalObject(), propertyName.publicName(), npIdentifier);
    466466}
    467467
  • trunk/Source/WebKit2/WebProcess/Plugins/Netscape/JSNPObject.h

    r160133 r160204  
    9696    static void getOwnPropertyNames(JSC::JSObject*, JSC::ExecState*, JSC::PropertyNameArray&, JSC::EnumerationMode);
    9797
    98     static JSC::EncodedJSValue propertyGetter(JSC::ExecState*, JSC::EncodedJSValue, JSC::EncodedJSValue, JSC::PropertyName);
    99     static JSC::EncodedJSValue methodGetter(JSC::ExecState*, JSC::EncodedJSValue, JSC::EncodedJSValue, JSC::PropertyName);
     98    static JSC::JSValue propertyGetter(JSC::ExecState*, JSC::JSValue, JSC::PropertyName);
     99    static JSC::JSValue methodGetter(JSC::ExecState*, JSC::JSValue, JSC::PropertyName);
    100100    static JSC::JSObject* throwInvalidAccessError(JSC::ExecState*);
    101101
  • trunk/Source/WebKit2/WebProcess/Plugins/Netscape/NPRuntimeObjectMap.cpp

    r160133 r160204  
    7373    // If this is a JSNPObject, we can just get its underlying NPObject.
    7474    if (jsObject->classInfo() == JSNPObject::info()) {
    75         JSNPObject* jsNPObject = jsCast<JSNPObject*>(jsObject);
     75        JSNPObject* jsNPObject = static_cast<JSNPObject*>(jsObject);
    7676        NPObject* npObject = jsNPObject->npObject();
    7777       
     
    303303void NPRuntimeObjectMap::finalize(JSC::Handle<JSC::Unknown> handle, void* context)
    304304{
    305     JSNPObject* object = jsCast<JSNPObject*>(handle.get().asCell());
     305    JSNPObject* object = static_cast<JSNPObject*>(handle.get().asCell());
    306306    weakRemove(m_jsNPObjects, static_cast<NPObject*>(context), object);
    307307    addToInvalidationQueue(object->leakNPObject());
  • trunk/Source/WebKit2/WebProcess/WebPage/WebFrame.cpp

    r160133 r160204  
    665665        return String();
    666666
    667     return counterValueForElement(&jsCast<JSElement*>(toJS(element))->impl());
     667    return counterValueForElement(&static_cast<JSElement*>(toJS(element))->impl());
    668668}
    669669
Note: See TracChangeset for help on using the changeset viewer.