aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/jsruntime/qv4objectiterator.cpp
diff options
context:
space:
mode:
authorLars Knoll <lars.knoll@qt.io>2018-06-23 20:08:40 +0200
committerLars Knoll <lars.knoll@qt.io>2018-07-02 19:29:32 +0000
commit56602df447c5f16257874f2e97b078dcf76f2467 (patch)
tree901c76eb6262dad80e6ab94af810c645355cb6d5 /src/qml/jsruntime/qv4objectiterator.cpp
parentdb695c5b1d07275f208446dad178b1131b20bb0a (diff)
Cleanups in the Identifier API
Rename from/asHeapObject to from/asStringOrSymbol and fix the signature. Add a isStringOrSymbol() method and redefine isValid() to also include array indices. Change-Id: Ic8272bfbe84d15421e2ebe86ddda7fdaa8db4f3e Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Diffstat (limited to 'src/qml/jsruntime/qv4objectiterator.cpp')
-rw-r--r--src/qml/jsruntime/qv4objectiterator.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/qml/jsruntime/qv4objectiterator.cpp b/src/qml/jsruntime/qv4objectiterator.cpp
index fc4a06747f..b656c16739 100644
--- a/src/qml/jsruntime/qv4objectiterator.cpp
+++ b/src/qml/jsruntime/qv4objectiterator.cpp
@@ -105,7 +105,7 @@ void ObjectIterator::next(Value *name, uint *index, Property *pd, PropertyAttrib
bool shadowed = false;
while (o->d() != current->heapObject()) {
Identifier id = n ? (n->makeIdentifier(), n->identifier()) : Identifier::fromArrayIndex(*index);
- if ((id.isValid() ||id.isArrayIndex()) && o->getOwnProperty(id) != Attr_Invalid) {
+ if (id.isValid() && o->getOwnProperty(id) != Attr_Invalid) {
shadowed = true;
break;
}