X-Git-Url: https://git.saurik.com/apple/javascriptcore.git/blobdiff_plain/ba379fdc102753d6be2c4d937058fe40257329fe..14957cd040308e3eeec43d26bae5d76da13fcd85:/runtime/PropertySlot.cpp diff --git a/runtime/PropertySlot.cpp b/runtime/PropertySlot.cpp index 36fa5d8..fd16c0c 100644 --- a/runtime/PropertySlot.cpp +++ b/runtime/PropertySlot.cpp @@ -23,23 +23,18 @@ #include "JSFunction.h" #include "JSGlobalObject.h" -#include "JSObject.h" namespace JSC { -JSValue PropertySlot::functionGetter(ExecState* exec, const Identifier&, const PropertySlot& slot) +JSValue PropertySlot::functionGetter(ExecState* exec) const { // Prevent getter functions from observing execution if an exception is pending. if (exec->hadException()) return exec->exception(); CallData callData; - CallType callType = slot.m_data.getterFunc->getCallData(callData); - if (callType == CallTypeHost) - return callData.native.function(exec, slot.m_data.getterFunc, slot.slotBase(), exec->emptyList()); - ASSERT(callType == CallTypeJS); - // FIXME: Can this be done more efficiently using the callData? - return static_cast(slot.m_data.getterFunc)->call(exec, slot.slotBase(), exec->emptyList()); + CallType callType = m_data.getterFunc->getCallData(callData); + return call(exec, m_data.getterFunc, callType, callData, thisValue(), exec->emptyList()); } } // namespace JSC