diff options
author | Lars Knoll <lars.knoll@qt.io> | 2017-10-21 15:55:45 +0200 |
---|---|---|
committer | Lars Knoll <lars.knoll@qt.io> | 2017-11-07 21:07:41 +0000 |
commit | 6e3317bb171c718250bbb736567fc0e4812a6241 (patch) | |
tree | f4bbea80d807093ee077cb30a516517f2b47aacf /src/qml/jsruntime/qv4globalobject.cpp | |
parent | 7f4a2f38b0440cc296949069822ae14d0b392da8 (diff) |
Change signature for call/callAsConstructor
Change-Id: I159b57acc7a2133ef1ad545aa84e792c63449a57
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Diffstat (limited to 'src/qml/jsruntime/qv4globalobject.cpp')
-rw-r--r-- | src/qml/jsruntime/qv4globalobject.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/qml/jsruntime/qv4globalobject.cpp b/src/qml/jsruntime/qv4globalobject.cpp index f962aa29bc..a015461c47 100644 --- a/src/qml/jsruntime/qv4globalobject.cpp +++ b/src/qml/jsruntime/qv4globalobject.cpp @@ -338,9 +338,9 @@ void Heap::EvalFunction::init(QV4::ExecutionContext *scope) f->defineReadonlyProperty(s.engine->id_length(), Primitive::fromInt32(1)); } -ReturnedValue EvalFunction::evalCall(CallData *callData, bool directCall) const +ReturnedValue EvalFunction::evalCall(const Value *, const Value *argv, int argc, bool directCall) const { - if (callData->argc() < 1) + if (argc < 1) return Encode::undefined(); ExecutionEngine *v4 = engine(); @@ -354,9 +354,9 @@ ReturnedValue EvalFunction::evalCall(CallData *callData, bool directCall) const ctx = v4->rootContext(); } - String *scode = callData->args[0].stringValue(); + String *scode = argv[0].stringValue(); if (!scode) - return callData->args[0].asReturnedValue(); + return argv[0].asReturnedValue(); const QString code = scode->toQString(); bool inheritContext = !ctx->d()->v4Function->isStrict(); @@ -396,10 +396,10 @@ ReturnedValue EvalFunction::evalCall(CallData *callData, bool directCall) const } -ReturnedValue EvalFunction::call(const Managed *that, CallData *callData) +ReturnedValue EvalFunction::call(const FunctionObject *f, const Value *thisObject, const Value *argv, int argc) { // indirect call - return static_cast<const EvalFunction *>(that)->evalCall(callData, false); + return static_cast<const EvalFunction *>(f)->evalCall(thisObject, argv, argc, false); } |