aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/jsruntime/qv4functionobject.cpp
diff options
context:
space:
mode:
authorLars Knoll <lars.knoll@qt.io>2018-09-18 10:39:47 +0200
committerLars Knoll <lars.knoll@qt.io>2018-09-23 17:27:35 +0000
commit3ff776b74e3d9c0af911e331cdb649fd3fa0dd09 (patch)
tree98f3a8b8f1fcf19885add0bc4c1402ee8d1783a7 /src/qml/jsruntime/qv4functionobject.cpp
parentc7d097297d789dd7c32a77d8a038067db364734b (diff)
Remove unused argument
Change-Id: I1f2c796b50d05c238fad36434b2545604a401fbf Reviewed-by: Erik Verbruggen <erik.verbruggen@qt.io>
Diffstat (limited to 'src/qml/jsruntime/qv4functionobject.cpp')
-rw-r--r--src/qml/jsruntime/qv4functionobject.cpp13
1 files changed, 6 insertions, 7 deletions
diff --git a/src/qml/jsruntime/qv4functionobject.cpp b/src/qml/jsruntime/qv4functionobject.cpp
index a2a5cdd474..b4d68717d3 100644
--- a/src/qml/jsruntime/qv4functionobject.cpp
+++ b/src/qml/jsruntime/qv4functionobject.cpp
@@ -83,20 +83,19 @@ void Heap::FunctionObject::init(QV4::ExecutionContext *scope, QV4::String *name,
f->setName(name);
}
-void Heap::FunctionObject::init(QV4::ExecutionContext *scope, QV4::String *name, bool createProto)
+void Heap::FunctionObject::init(QV4::ExecutionContext *scope, QV4::String *name)
{
+ ExecutionEngine *e = scope->engine();
+
jsCall = vtable()->call;
jsConstruct = vtable()->callAsConstructor;
Object::init();
this->scope.set(scope->engine(), scope->d());
- Scope s(scope->engine());
+ Scope s(e);
ScopedFunctionObject f(s, this);
if (name)
f->setName(name);
-
- if (createProto)
- f->createDefaultPrototypeProperty(Heap::FunctionObject::Index_ProtoConstructor);
}
@@ -116,11 +115,11 @@ void Heap::FunctionObject::init(QV4::ExecutionContext *scope, Function *function
f->setName(name);
}
-void Heap::FunctionObject::init(QV4::ExecutionContext *scope, const QString &name, bool createProto)
+void Heap::FunctionObject::init(QV4::ExecutionContext *scope, const QString &name)
{
Scope valueScope(scope);
ScopedString s(valueScope, valueScope.engine->newString(name));
- init(scope, s, createProto);
+ init(scope, s);
}
void Heap::FunctionObject::init()