aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/qml/qml/v4vm/qv4engine.cpp2
-rw-r--r--src/qml/qml/v4vm/qv4engine_p.h6
-rw-r--r--src/qml/qml/v4vm/qv4regexp.cpp2
-rw-r--r--src/qml/qml/v4vm/qv4regexpobject_p.h3
-rw-r--r--src/qml/qml/v4vm/qv4runtime_p.h2
5 files changed, 10 insertions, 5 deletions
diff --git a/src/qml/qml/v4vm/qv4engine.cpp b/src/qml/qml/v4vm/qv4engine.cpp
index a81b492345..cd0a16bfa5 100644
--- a/src/qml/qml/v4vm/qv4engine.cpp
+++ b/src/qml/qml/v4vm/qv4engine.cpp
@@ -68,6 +68,7 @@ namespace VM {
ExecutionEngine::ExecutionEngine(EvalISelFactory *factory)
: memoryManager(new QQmlJS::VM::MemoryManager)
, executableAllocator(new QQmlJS::VM::ExecutableAllocator)
+ , bumperPointerAllocator(new WTF::BumpPointerAllocator)
, debugger(0)
, globalObject(0)
, globalCode(0)
@@ -237,6 +238,7 @@ ExecutionEngine::ExecutionEngine(EvalISelFactory *factory)
ExecutionEngine::~ExecutionEngine()
{
+ delete bumperPointerAllocator;
delete regExpCache;
UnwindHelper::deregisterFunctions(functions);
qDeleteAll(functions);
diff --git a/src/qml/qml/v4vm/qv4engine_p.h b/src/qml/qml/v4vm/qv4engine_p.h
index 7777ca59eb..00466659fc 100644
--- a/src/qml/qml/v4vm/qv4engine_p.h
+++ b/src/qml/qml/v4vm/qv4engine_p.h
@@ -49,7 +49,9 @@
#include "qv4property_p.h"
#include <setjmp.h>
-#include <wtf/BumpPointerAllocator.h>
+namespace WTF {
+class BumpPointerAllocator;
+}
QT_BEGIN_NAMESPACE
@@ -115,7 +117,7 @@ struct Q_QML_EXPORT ExecutionEngine
ExecutionContext *current;
GlobalContext *rootContext;
- WTF::BumpPointerAllocator bumperPointerAllocator; // Used by Yarr Regex engine.
+ WTF::BumpPointerAllocator *bumperPointerAllocator; // Used by Yarr Regex engine.
Identifiers *identifierCache;
diff --git a/src/qml/qml/v4vm/qv4regexp.cpp b/src/qml/qml/v4vm/qv4regexp.cpp
index 0ca3ae95c2..4ad04b9b26 100644
--- a/src/qml/qml/v4vm/qv4regexp.cpp
+++ b/src/qml/qml/v4vm/qv4regexp.cpp
@@ -109,7 +109,7 @@ RegExp::RegExp(ExecutionEngine* engine, const QString &pattern, bool ignoreCase,
if (error)
return;
m_subPatternCount = yarrPattern.m_numSubpatterns;
- m_byteCode = JSC::Yarr::byteCompile(yarrPattern, &engine->bumperPointerAllocator);
+ m_byteCode = JSC::Yarr::byteCompile(yarrPattern, engine->bumperPointerAllocator);
#if ENABLE(YARR_JIT)
if (!yarrPattern.m_containsBackreferences) {
JSC::JSGlobalData dummy(engine->executableAllocator);
diff --git a/src/qml/qml/v4vm/qv4regexpobject_p.h b/src/qml/qml/v4vm/qv4regexpobject_p.h
index af30027295..4c2e290233 100644
--- a/src/qml/qml/v4vm/qv4regexpobject_p.h
+++ b/src/qml/qml/v4vm/qv4regexpobject_p.h
@@ -51,7 +51,6 @@
#include "qv4managed_p.h"
#include "qv4property_p.h"
#include "qv4objectiterator_p.h"
-#include "qv4regexp_p.h"
#include <QtCore/QString>
#include <QtCore/QHash>
@@ -64,6 +63,8 @@ QT_BEGIN_NAMESPACE
namespace QQmlJS {
namespace VM {
+struct RegExp;
+
struct RegExpObject: Object {
RegExp* value;
Property *lastIndexProperty(ExecutionContext *ctx);
diff --git a/src/qml/qml/v4vm/qv4runtime_p.h b/src/qml/qml/v4vm/qv4runtime_p.h
index b4cd826d1d..c718efc832 100644
--- a/src/qml/qml/v4vm/qv4runtime_p.h
+++ b/src/qml/qml/v4vm/qv4runtime_p.h
@@ -53,7 +53,7 @@
#include <cmath>
#include <cassert>
-#include <wtf/MathExtras.h>
+//#include <wtf/MathExtras.h>
#ifdef DO_TRACE_INSTR
# define TRACE1(x) fprintf(stderr, " %s\n", __FUNCTION__);