diff options
author | Lars Knoll <lars.knoll@digia.com> | 2014-11-24 15:38:41 +0100 |
---|---|---|
committer | Simon Hausmann <simon.hausmann@digia.com> | 2014-12-11 15:52:13 +0100 |
commit | 8afc1f7fe24c625cdb84406cc7665f1dcabf88c4 (patch) | |
tree | 04c5d73167544182e509ce7e40bd18c29909d0a7 /src/qml/jsruntime/qv4lookup.cpp | |
parent | 4322c8d7686c7cbbdf348146d32d705007b21d56 (diff) |
Move prototype back from the vtable into Object
This is the only way we can support a GC that moves
objects around in memory.
Change-Id: I1d168fae4aa9f575b730e469e762bc5b5549b886
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Diffstat (limited to 'src/qml/jsruntime/qv4lookup.cpp')
-rw-r--r-- | src/qml/jsruntime/qv4lookup.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/qml/jsruntime/qv4lookup.cpp b/src/qml/jsruntime/qv4lookup.cpp index e6f997d5df..ebdc7be200 100644 --- a/src/qml/jsruntime/qv4lookup.cpp +++ b/src/qml/jsruntime/qv4lookup.cpp @@ -243,11 +243,11 @@ ReturnedValue Lookup::getterGeneric(Lookup *l, ExecutionEngine *engine, const Va case Value::Null_Type: return engine->throwTypeError(); case Value::Boolean_Type: - proto = engine->booleanClass->prototype; + proto = engine->booleanPrototype.asObject(); break; case Value::Managed_Type: { Q_ASSERT(object->isString()); - proto = engine->stringObjectClass->prototype; + proto = engine->stringPrototype.asObject(); Scope scope(engine); ScopedString name(scope, engine->currentContext()->d()->compilationUnit->runtimeStrings[l->nameIndex]); if (name->equals(engine->id_length.getPointer())) { @@ -259,7 +259,7 @@ ReturnedValue Lookup::getterGeneric(Lookup *l, ExecutionEngine *engine, const Va } case Value::Integer_Type: default: // Number - proto = engine->numberClass->prototype; + proto = engine->numberPrototype.asObject(); } PropertyAttributes attrs; |