Chromium Code Reviews| Index: src/objects-inl.h |
| diff --git a/src/objects-inl.h b/src/objects-inl.h |
| index 0d83c4794666f1ed6e4b72bd1b74e8933e0d839b..99e053e77945ce977e802db301b45f3f955b9ca9 100644 |
| --- a/src/objects-inl.h |
| +++ b/src/objects-inl.h |
| @@ -4356,6 +4356,32 @@ MaybeObject* StringDictionaryShape::AsObject(String* key) { |
| } |
| +bool ObjectDictionaryShape::IsMatch(JSObject* key, Object* other) { |
| + ASSERT(other->IsJSObject()); |
|
Vitaly Repeshko
2011/07/26 13:53:14
JSObject::cast does the same assert.
Michael Starzinger
2011/07/26 22:30:23
Fixed.
|
| + return key == JSObject::cast(other); |
| +} |
| + |
| + |
| +uint32_t ObjectDictionaryShape::Hash(JSObject* key) { |
| + MaybeObject* maybe_hash = key->GetIdentityHash(); |
| + ASSERT(!maybe_hash->IsFailure()); |
| + return Smi::cast(maybe_hash->ToObjectUnchecked())->value(); |
| +} |
| + |
| + |
| +uint32_t ObjectDictionaryShape::HashForObject(JSObject* key, Object* other) { |
| + ASSERT(other->IsJSObject()); |
|
Vitaly Repeshko
2011/07/26 13:53:14
Ditto.
Michael Starzinger
2011/07/26 22:30:23
Fixed.
|
| + MaybeObject* maybe_hash = JSObject::cast(other)->GetIdentityHash(); |
| + ASSERT(!maybe_hash->IsFailure()); |
| + return Smi::cast(maybe_hash->ToObjectUnchecked())->value(); |
| +} |
| + |
| + |
| +MaybeObject* ObjectDictionaryShape::AsObject(JSObject* key) { |
| + return key; |
| +} |
| + |
| + |
| void Map::ClearCodeCache(Heap* heap) { |
| // No write barrier is needed since empty_fixed_array is not in new space. |
| // Please note this function is used during marking: |