| Index: src/objects-inl.h
|
| diff --git a/src/objects-inl.h b/src/objects-inl.h
|
| index 978704ac54286aff224e370390121e305cd45100..f72b3821f5f8023734bc179322e7ee4827c0b2e7 100644
|
| --- a/src/objects-inl.h
|
| +++ b/src/objects-inl.h
|
| @@ -920,6 +920,23 @@ bool Object::IsObjectHashTable() {
|
| }
|
|
|
|
|
| +bool Object::IsOrderedHashTable() {
|
| + return IsHeapObject() &&
|
| + HeapObject::cast(this)->map() ==
|
| + HeapObject::cast(this)->GetHeap()->ordered_hash_table_map();
|
| +}
|
| +
|
| +
|
| +bool Object::IsOrderedHashSet() {
|
| + return IsOrderedHashTable();
|
| +}
|
| +
|
| +
|
| +bool Object::IsOrderedHashMap() {
|
| + return IsOrderedHashTable();
|
| +}
|
| +
|
| +
|
| bool Object::IsPrimitive() {
|
| return IsOddball() || IsNumber() || IsString();
|
| }
|
| @@ -2963,6 +2980,8 @@ CAST_ACCESSOR(ExternalFloat64Array)
|
| CAST_ACCESSOR(ExternalUint8ClampedArray)
|
| CAST_ACCESSOR(Struct)
|
| CAST_ACCESSOR(AccessorInfo)
|
| +CAST_ACCESSOR(OrderedHashMap)
|
| +CAST_ACCESSOR(OrderedHashSet)
|
|
|
| template <class Traits>
|
| FixedTypedArray<Traits>* FixedTypedArray<Traits>::cast(Object* object) {
|
| @@ -6588,28 +6607,22 @@ MaybeObject* NameDictionaryShape::AsObject(Heap* heap, Name* key) {
|
| }
|
|
|
|
|
| -template <int entrysize>
|
| -bool ObjectHashTableShape<entrysize>::IsMatch(Object* key, Object* other) {
|
| +bool ObjectHashTableShape::IsMatch(Object* key, Object* other) {
|
| return key->SameValue(other);
|
| }
|
|
|
|
|
| -template <int entrysize>
|
| -uint32_t ObjectHashTableShape<entrysize>::Hash(Object* key) {
|
| +uint32_t ObjectHashTableShape::Hash(Object* key) {
|
| return Smi::cast(key->GetHash())->value();
|
| }
|
|
|
|
|
| -template <int entrysize>
|
| -uint32_t ObjectHashTableShape<entrysize>::HashForObject(Object* key,
|
| - Object* other) {
|
| +uint32_t ObjectHashTableShape::HashForObject(Object* key, Object* other) {
|
| return Smi::cast(other->GetHash())->value();
|
| }
|
|
|
|
|
| -template <int entrysize>
|
| -MaybeObject* ObjectHashTableShape<entrysize>::AsObject(Heap* heap,
|
| - Object* key) {
|
| +MaybeObject* ObjectHashTableShape::AsObject(Heap* heap, Object* key) {
|
| return key;
|
| }
|
|
|
|
|