summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/objects.cc7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/objects.cc b/src/objects.cc
index 904cf524..a30641b9 100644
--- a/src/objects.cc
+++ b/src/objects.cc
@@ -10102,6 +10102,13 @@ bool JSObject::HasRealElementProperty(uint32_t index) {
}
}
+ if (IsJSGlobalProxy()) {
+ Object* proto = GetPrototype();
+ if (proto->IsNull()) return false;
+ ASSERT(proto->IsJSGlobalObject());
+ return JSObject::cast(proto)->HasRealElementProperty(index);
+ }
+
// Handle [] on String objects.
if (this->IsStringObjectWithCharacterAt(index)) return true;