From 6a91dcba2e4fa85dc345c2d403c757ab7676e28c Mon Sep 17 00:00:00 2001 From: Lars Knoll Date: Wed, 9 Aug 2017 16:02:55 +0200 Subject: Always create a valid CallData object for interpreter calls This will allow removing a few more special cases and to simplify the code further. Change-Id: I3a958e9f68e3c103ea4f2ee6825f893e5931b11d Reviewed-by: Simon Hausmann --- src/qml/jsruntime/qv4functionobject.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/qml/jsruntime/qv4functionobject.cpp') diff --git a/src/qml/jsruntime/qv4functionobject.cpp b/src/qml/jsruntime/qv4functionobject.cpp index 3549c6b9ea..27810dc836 100644 --- a/src/qml/jsruntime/qv4functionobject.cpp +++ b/src/qml/jsruntime/qv4functionobject.cpp @@ -368,7 +368,7 @@ ReturnedValue ScriptFunction::construct(const Managed *that, CallData *callData) QV4::Function *v4Function = f->function(); Q_ASSERT(v4Function); - ReturnedValue result = ExecutionContext::call(f->scope(), callData, v4Function, f); + ReturnedValue result = v4Function->call(f->scope(), callData, f); if (Q_UNLIKELY(v4->hasException)) return Encode::undefined(); @@ -388,7 +388,7 @@ ReturnedValue ScriptFunction::call(const Managed *that, CallData *callData) QV4::Function *v4Function = f->function(); Q_ASSERT(v4Function); - return ExecutionContext::call(f->scope(), callData, v4Function, f); + return v4Function->call(f->scope(), callData, f); } void Heap::ScriptFunction::init(QV4::ExecutionContext *scope, Function *function) -- cgit v1.2.3