summaryrefslogtreecommitdiffstats
path: root/src/3rdparty/webkit/JavaScriptCore/runtime/ConstructData.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/3rdparty/webkit/JavaScriptCore/runtime/ConstructData.h')
-rw-r--r--src/3rdparty/webkit/JavaScriptCore/runtime/ConstructData.h35
1 files changed, 34 insertions, 1 deletions
diff --git a/src/3rdparty/webkit/JavaScriptCore/runtime/ConstructData.h b/src/3rdparty/webkit/JavaScriptCore/runtime/ConstructData.h
index 9d580d579..477399c16 100644
--- a/src/3rdparty/webkit/JavaScriptCore/runtime/ConstructData.h
+++ b/src/3rdparty/webkit/JavaScriptCore/runtime/ConstructData.h
@@ -46,9 +46,42 @@ namespace JSC {
typedef JSObject* (*NativeConstructor)(ExecState*, JSObject*, const ArgList&);
- union ConstructData {
+#ifdef QT_BUILD_SCRIPT_LIB
+ class NativeConstrWrapper
+ {
+ NativeConstructor ptr;
+ //Hack. If this variable is true and if debugger is attached at the end of
+ //operator() execution functionExit event will be created (in most cases it will be default)
+ //This variable was created because of FunctionWrapper::proxyCall method that change result
+ //on fly. Event shuld be created with original value so the method should call it itself.
+ bool callDebuggerFunctionExit;
+ public:
+ inline NativeConstrWrapper& operator=(NativeConstructor func)
+ {
+ callDebuggerFunctionExit = true;
+ ptr = func;
+ return *this;
+ }
+ inline operator NativeConstructor() const {return ptr;}
+ inline operator bool() const {return ptr;}
+
+ inline void doNotCallDebuggerFunctionExit() {callDebuggerFunctionExit = false;}
+ JSObject* operator()(ExecState*, JSObject*, const ArgList&) const;
+ };
+#endif
+
+#if defined(QT_BUILD_SCRIPT_LIB) && PLATFORM(SOLARIS)
+ struct
+#else
+ union
+#endif
+ ConstructData {
struct {
+#ifndef QT_BUILD_SCRIPT_LIB
NativeConstructor function;
+#else
+ NativeConstrWrapper function;
+#endif
} native;
struct {
FunctionBodyNode* functionBody;