aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins
diff options
context:
space:
mode:
authorLars Knoll <lars.knoll@qt.io>2017-08-30 21:53:03 +0200
committerLars Knoll <lars.knoll@qt.io>2017-09-01 12:30:49 +0000
commit6df6f642ea382169533a0ad106be270b6d4b7d58 (patch)
tree143401796a060f2e9aef61f9e5bf9a5ffa34a73b /src/plugins
parentcc7a858698063649f9770a89949354e2b58ae288 (diff)
Move CallContext construction into a interpreter instruction
This will allow us to further cut down on function call overhead. To make this work, introduce a proper distinction between EvalCode and GlobalCode and use the correct compilation mode in all places. Change-Id: I070621142159b7416026347c9239200c5ed7a56b Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Diffstat (limited to 'src/plugins')
-rw-r--r--src/plugins/qmltooling/qmldbg_debugger/qv4debugjob.cpp2
-rw-r--r--src/plugins/qmltooling/qmldbg_nativedebugger/qqmlnativedebugservice.cpp2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/plugins/qmltooling/qmldbg_debugger/qv4debugjob.cpp b/src/plugins/qmltooling/qmldbg_debugger/qv4debugjob.cpp
index 625095b340..b0607c574a 100644
--- a/src/plugins/qmltooling/qmldbg_debugger/qv4debugjob.cpp
+++ b/src/plugins/qmltooling/qmldbg_debugger/qv4debugjob.cpp
@@ -101,7 +101,7 @@ void JavaScriptJob::run()
}
}
- QV4::Script script(ctx, this->script);
+ QV4::Script script(ctx, QV4::Compiler::EvalCode, this->script);
script.strictMode = ctx->d()->v4Function->isStrict();
// In order for property lookups in QML to work, we need to disable fast v4 lookups. That
// is a side-effect of inheritContext.
diff --git a/src/plugins/qmltooling/qmldbg_nativedebugger/qqmlnativedebugservice.cpp b/src/plugins/qmltooling/qmldbg_nativedebugger/qqmlnativedebugservice.cpp
index 5015c39c8e..1eaa2819af 100644
--- a/src/plugins/qmltooling/qmldbg_nativedebugger/qqmlnativedebugservice.cpp
+++ b/src/plugins/qmltooling/qmldbg_nativedebugger/qqmlnativedebugservice.cpp
@@ -251,7 +251,7 @@ QV4::ReturnedValue NativeDebugger::evaluateExpression(const QString &expression)
QV4::ExecutionContext *ctx = m_engine->currentContext();
- QV4::Script script(ctx, expression);
+ QV4::Script script(ctx, QV4::Compiler::EvalCode, expression);
script.strictMode = ctx->d()->v4Function->isStrict();
// In order for property lookups in QML to work, we need to disable fast v4 lookups.
// That is a side-effect of inheritContext.