diff options
author | Lars Knoll <lars.knoll@digia.com> | 2013-04-08 15:38:30 +0200 |
---|---|---|
committer | Simon Hausmann <simon.hausmann@digia.com> | 2013-04-12 14:25:21 +0200 |
commit | 1e87e39a1987da9f0ad454b8b4f6c40055e50799 (patch) | |
tree | 864b0405eb46e578045741883e03ad39532ac869 /src/v4/qv4engine.cpp | |
parent | 78bef0f2288de34f68525721733e43c769eb4496 (diff) |
Change internal class when attributes of properties change
This should allow us to share property attributes for different
class instances saving quite some memory. In addition, it
can be used to speed up property access (as we then know in the
lookup whether it's a data or accessor property).
Change-Id: Ide9c6168a07b5c83a1e73d075d8fc4f6594e08fd
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Diffstat (limited to 'src/v4/qv4engine.cpp')
-rw-r--r-- | src/v4/qv4engine.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/v4/qv4engine.cpp b/src/v4/qv4engine.cpp index 54655d173b..24770d20a9 100644 --- a/src/v4/qv4engine.cpp +++ b/src/v4/qv4engine.cpp @@ -109,7 +109,7 @@ ExecutionEngine::ExecutionEngine(EvalISelFactory *factory) id_eval = newIdentifier(QStringLiteral("eval")); emptyClass = new InternalClass(this); - arrayClass = emptyClass->addMember(id_length); + arrayClass = emptyClass->addMember(id_length, Attr_ReadOnly); initRootContext(); objectPrototype = new (memoryManager) ObjectPrototype(this); |