aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/jsruntime/qv4functionobject.cpp
diff options
context:
space:
mode:
authorErik Verbruggen <erik.verbruggen@digia.com>2016-09-07 14:58:59 +0200
committerErik Verbruggen <erik.verbruggen@qt.io>2016-09-28 08:46:50 +0000
commit53ef0406b70e57c451e89c4bb9a6dcb4c438af86 (patch)
treed651ecd6e3db5090d5d1dfdd67a7af42523b8438 /src/qml/jsruntime/qv4functionobject.cpp
parent765f3afccb34b16c249c609d788374320cfbd25d (diff)
QML: Make QV4::Heap::Pointer trivial
One more step needed to make QV4::Heap::structs trivial. Change-Id: I6bebfaff970518d65a09f2b9f50a6855c431d4c0 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Diffstat (limited to 'src/qml/jsruntime/qv4functionobject.cpp')
-rw-r--r--src/qml/jsruntime/qv4functionobject.cpp32
1 files changed, 16 insertions, 16 deletions
diff --git a/src/qml/jsruntime/qv4functionobject.cpp b/src/qml/jsruntime/qv4functionobject.cpp
index b08ad24fbe..df9f92b259 100644
--- a/src/qml/jsruntime/qv4functionobject.cpp
+++ b/src/qml/jsruntime/qv4functionobject.cpp
@@ -69,18 +69,18 @@ using namespace QV4;
DEFINE_OBJECT_VTABLE(FunctionObject);
Heap::FunctionObject::FunctionObject(QV4::ExecutionContext *scope, QV4::String *name, bool createProto)
- : scope(scope->d())
- , function(Q_NULLPTR)
+ : function(Q_NULLPTR)
{
+ this->scope = scope->d();
Scope s(scope->engine());
ScopedFunctionObject f(s, this);
f->init(name, createProto);
}
Heap::FunctionObject::FunctionObject(QV4::ExecutionContext *scope, Function *function, bool createProto)
- : scope(scope->d())
- , function(Q_NULLPTR)
+ : function(Q_NULLPTR)
{
+ this->scope = scope->d();
Scope s(scope->engine());
ScopedString name(s, function->name());
ScopedFunctionObject f(s, this);
@@ -88,9 +88,9 @@ Heap::FunctionObject::FunctionObject(QV4::ExecutionContext *scope, Function *fun
}
Heap::FunctionObject::FunctionObject(QV4::ExecutionContext *scope, const QString &name, bool createProto)
- : scope(scope->d())
- , function(Q_NULLPTR)
+ : function(Q_NULLPTR)
{
+ this->scope = scope->d();
Scope s(scope->engine());
ScopedFunctionObject f(s, this);
ScopedString n(s, s.engine->newString(name));
@@ -98,9 +98,9 @@ Heap::FunctionObject::FunctionObject(QV4::ExecutionContext *scope, const QString
}
Heap::FunctionObject::FunctionObject(ExecutionContext *scope, const QString &name, bool createProto)
- : scope(scope)
- , function(Q_NULLPTR)
+ : function(Q_NULLPTR)
{
+ this->scope = scope;
Scope s(scope->engine);
ScopedFunctionObject f(s, this);
ScopedString n(s, s.engine->newString(name));
@@ -108,9 +108,9 @@ Heap::FunctionObject::FunctionObject(ExecutionContext *scope, const QString &nam
}
Heap::FunctionObject::FunctionObject(QV4::ExecutionContext *scope, const ReturnedValue name)
- : scope(scope->d())
- , function(Q_NULLPTR)
+ : function(Q_NULLPTR)
{
+ this->scope = scope->d();
Scope s(scope);
ScopedFunctionObject f(s, this);
ScopedString n(s, name);
@@ -118,9 +118,9 @@ Heap::FunctionObject::FunctionObject(QV4::ExecutionContext *scope, const Returne
}
Heap::FunctionObject::FunctionObject(ExecutionContext *scope, const ReturnedValue name)
- : scope(scope)
- , function(Q_NULLPTR)
+ : function(Q_NULLPTR)
{
+ this->scope = scope;
Scope s(scope->engine);
ScopedFunctionObject f(s, this);
ScopedString n(s, name);
@@ -128,9 +128,9 @@ Heap::FunctionObject::FunctionObject(ExecutionContext *scope, const ReturnedValu
}
Heap::FunctionObject::FunctionObject()
- : scope(internalClass->engine->rootContext()->d())
- , function(Q_NULLPTR)
+ : function(Q_NULLPTR)
{
+ this->scope = internalClass->engine->rootContext()->d();
Q_ASSERT(internalClass && internalClass->find(internalClass->engine->id_prototype()) == Index_Prototype);
*propertyData(Index_Prototype) = Encode::undefined();
}
@@ -667,9 +667,9 @@ DEFINE_OBJECT_VTABLE(BoundFunction);
Heap::BoundFunction::BoundFunction(QV4::ExecutionContext *scope, QV4::FunctionObject *target,
const Value &boundThis, QV4::MemberData *boundArgs)
: Heap::FunctionObject(scope, QStringLiteral("__bound function__"))
- , target(target->d())
- , boundArgs(boundArgs ? boundArgs->d() : 0)
{
+ this->target = target->d();
+ this->boundArgs = boundArgs ? boundArgs->d() : 0;
this->boundThis = boundThis;
Scope s(scope);