summaryrefslogtreecommitdiff
path: root/tests/auto/qscriptengine/tst_qscriptengine.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'tests/auto/qscriptengine/tst_qscriptengine.cpp')
-rw-r--r--tests/auto/qscriptengine/tst_qscriptengine.cpp17
1 files changed, 2 insertions, 15 deletions
diff --git a/tests/auto/qscriptengine/tst_qscriptengine.cpp b/tests/auto/qscriptengine/tst_qscriptengine.cpp
index 514d29a..3be9d62 100644
--- a/tests/auto/qscriptengine/tst_qscriptengine.cpp
+++ b/tests/auto/qscriptengine/tst_qscriptengine.cpp
@@ -53,6 +53,8 @@
#include <QtScript/private/qscriptdeclarativeclass_p.h>
+#include "../shared/util.h"
+
Q_DECLARE_METATYPE(QList<int>)
Q_DECLARE_METATYPE(QObjectList)
Q_DECLARE_METATYPE(QScriptProgram)
@@ -63,21 +65,6 @@ Q_DECLARE_METATYPE(QScriptProgram)
# define SRCDIR "C:/Private/" TOSTRING(SYMBIAN_SRCDIR_UID)
#endif
-// The JavaScriptCore GC marks the C stack. To try to ensure that there is
-// no JSObject* left in stack memory by the compiler, we call this function
-// to zap some bytes of memory before calling collectGarbage().
-static void zapSomeStack()
-{
- char buf[4096];
- memset(buf, 0, sizeof(buf));
-}
-
-static void collectGarbage_helper(QScriptEngine &eng)
-{
- zapSomeStack();
- eng.collectGarbage();
-}
-
class tst_QScriptEngine : public QObject
{
Q_OBJECT