aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/jsruntime/qv4functionobject_p.h
diff options
context:
space:
mode:
authorLars Knoll <lars.knoll@qt.io>2018-04-10 22:45:27 +0200
committerLars Knoll <lars.knoll@qt.io>2018-04-12 13:58:48 +0000
commit278b144a35fb5e5068877cfd456b58d690b9caaf (patch)
tree181a1d6ae73e56ac6f186839b2763d0e89fb554e /src/qml/jsruntime/qv4functionobject_p.h
parent6c2f6e029ea39aada85b297721a366faaa8aeb5f (diff)
Disambiguate different allocation functions in the memory manager
Some compilers (in this case MingW 5.3) don't manage to properly disambiguate the template overloads, and try to instantiate the wrong template function. Solve this by renaming the one of the template functions. Change-Id: I3574e617fe96c4bd52920a0127a1dfe39cc3d302 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Diffstat (limited to 'src/qml/jsruntime/qv4functionobject_p.h')
-rw-r--r--src/qml/jsruntime/qv4functionobject_p.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/qml/jsruntime/qv4functionobject_p.h b/src/qml/jsruntime/qv4functionobject_p.h
index d6066ec648..373d7fe39e 100644
--- a/src/qml/jsruntime/qv4functionobject_p.h
+++ b/src/qml/jsruntime/qv4functionobject_p.h
@@ -167,7 +167,7 @@ struct Q_QML_EXPORT FunctionObject: Object {
static Heap::FunctionObject *createBuiltinFunction(ExecutionContext *scope, String *name,
ReturnedValue (*code)(const FunctionObject *, const Value *thisObject, const Value *argv, int argc))
{
- return scope->engine()->memoryManager->allocObject<FunctionObject>(scope, name, code);
+ return scope->engine()->memoryManager->allocate<FunctionObject>(scope, name, code);
}
bool strictMode() const { return d()->function ? d()->function->isStrict() : false; }
@@ -234,7 +234,7 @@ struct BoundFunction: FunctionObject {
static Heap::BoundFunction *create(ExecutionContext *scope, FunctionObject *target, const Value &boundThis, QV4::MemberData *boundArgs)
{
- return scope->engine()->memoryManager->allocObject<BoundFunction>(scope, target, boundThis, boundArgs);
+ return scope->engine()->memoryManager->allocate<BoundFunction>(scope, target, boundThis, boundArgs);
}
Heap::FunctionObject *target() const { return d()->target; }