diff options
Diffstat (limited to 'Source/JavaScriptCore/runtime/PropertyMapHashTable.h')
-rw-r--r-- | Source/JavaScriptCore/runtime/PropertyMapHashTable.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/Source/JavaScriptCore/runtime/PropertyMapHashTable.h b/Source/JavaScriptCore/runtime/PropertyMapHashTable.h index 7c8cabb7b..c47f3476a 100644 --- a/Source/JavaScriptCore/runtime/PropertyMapHashTable.h +++ b/Source/JavaScriptCore/runtime/PropertyMapHashTable.h @@ -325,7 +325,7 @@ inline PropertyTable::const_iterator PropertyTable::end() const inline PropertyTable::find_iterator PropertyTable::find(const KeyType& key) { ASSERT(key); - ASSERT(key->isIdentifier()); + ASSERT(key->isIdentifier() || key->isEmptyUnique()); unsigned hash = key->existingHash(); unsigned step = 0; @@ -369,7 +369,8 @@ inline PropertyTable::find_iterator PropertyTable::findWithString(const KeyType& unsigned entryIndex = m_index[hash & m_indexMask]; if (entryIndex == EmptyEntryIndex) return std::make_pair((ValueType*)0, hash & m_indexMask); - if (equal(key, table()[entryIndex - 1].key)) + const KeyType& keyInMap = table()[entryIndex - 1].key; + if (equal(key, keyInMap) && keyInMap->isIdentifier()) return std::make_pair(&table()[entryIndex - 1], hash & m_indexMask); #if DUMP_PROPERTYMAP_STATS |