From d6fb8791ab8734455398ac556fd035dc08a1a0a6 Mon Sep 17 00:00:00 2001 From: Ulf Hermann Date: Wed, 2 Dec 2020 10:18:34 +0100 Subject: Let AOT-compiled functions modify their arguments It allows for more natural looking generated code and there is no downside. The arguments are specially prepared for the call anyway. Change-Id: I8437e93adb1c67db1b53fbdb29cbea10f6ef278f Reviewed-by: Fabian Kosmale --- src/qml/jsruntime/qv4vme_moth.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/qml/jsruntime') diff --git a/src/qml/jsruntime/qv4vme_moth.cpp b/src/qml/jsruntime/qv4vme_moth.cpp index 98a6d94ecc..4815f5ad91 100644 --- a/src/qml/jsruntime/qv4vme_moth.cpp +++ b/src/qml/jsruntime/qv4vme_moth.cpp @@ -491,7 +491,7 @@ ReturnedValue VME::exec(CppStackFrame *frame, ExecutionEngine *engine) Scoped qmlContext(scope, engine->qmlContext()); function->aotFunction->functionPtr( qmlContext->qmlContext()->asQQmlContext(), qmlContext->qmlScope(), - returnValue, const_cast(argumentPtrs)); // We're adding const here + returnValue, argumentPtrs); if (returnValue) { result = engine->metaTypeToJS(returnType.id(), returnValue); -- cgit v1.2.3