X-Git-Url: https://git.saurik.com/apple/javascriptcore.git/blobdiff_plain/14957cd040308e3eeec43d26bae5d76da13fcd85..2656c66b5b30d5597e842a751c7f19ad6c2fe31a:/runtime/CallData.h diff --git a/runtime/CallData.h b/runtime/CallData.h index b138f54..b6edd37 100644 --- a/runtime/CallData.h +++ b/runtime/CallData.h @@ -10,7 +10,7 @@ * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. - * 3. Neither the name of Apple Computer, Inc. ("Apple") nor the names of + * 3. Neither the name of Apple Inc. ("Apple") nor the names of * its contributors may be used to endorse or promote products derived * from this software without specific prior written permission. * @@ -29,35 +29,36 @@ #ifndef CallData_h #define CallData_h -#include "JSValue.h" +#include "JSCJSValue.h" namespace JSC { - class ArgList; - class ExecState; - class FunctionExecutable; - class JSObject; - class ScopeChainNode; +class ArgList; +class ExecState; +class FunctionExecutable; +class JSObject; +class JSScope; - enum CallType { - CallTypeNone, - CallTypeHost, - CallTypeJS - }; +enum CallType { + CallTypeNone, + CallTypeHost, + CallTypeJS +}; - typedef EncodedJSValue (JSC_HOST_CALL *NativeFunction)(ExecState*); +typedef EncodedJSValue (JSC_HOST_CALL *NativeFunction)(ExecState*); - union CallData { - struct { - NativeFunction function; - } native; - struct { - FunctionExecutable* functionExecutable; - ScopeChainNode* scopeChain; - } js; - }; +union CallData { + struct { + NativeFunction function; + } native; + struct { + FunctionExecutable* functionExecutable; + JSScope* scope; + } js; +}; - JSValue call(ExecState*, JSValue functionObject, CallType, const CallData&, JSValue thisValue, const ArgList&); +JS_EXPORT_PRIVATE JSValue call(ExecState*, JSValue functionObject, CallType, const CallData&, JSValue thisValue, const ArgList&); +JS_EXPORT_PRIVATE JSValue call(ExecState*, JSValue functionObject, CallType, const CallData&, JSValue thisValue, const ArgList&, JSValue* exception); } // namespace JSC