| Index: src/types.cc
|
| diff --git a/src/types.cc b/src/types.cc
|
| index 1c6b84e2dc67da07ce3c809810b163bf306e2ca1..f07196a06c7816b062eb1b87708c28bd20aaad93 100644
|
| --- a/src/types.cc
|
| +++ b/src/types.cc
|
| @@ -180,6 +180,7 @@ TypeImpl<Config>::BitsetType::Lub(TypeImpl* type) {
|
| if (type->IsContext()) return kInternal & kTaggedPointer;
|
| if (type->IsArray()) return kOtherObject;
|
| if (type->IsFunction()) return kOtherObject; // TODO(rossberg): kFunction
|
| + if (type->IsObject()) return kOtherObject;
|
| UNREACHABLE();
|
| return kNone;
|
| }
|
| @@ -473,6 +474,18 @@ bool TypeImpl<Config>::SimplyEquals(TypeImpl* that) {
|
| }
|
| return true;
|
| }
|
| + if (that->IsObject()) {
|
| + if (!this->IsObject()) return false;
|
| + ObjectType* this_obj = this->AsObject();
|
| + ObjectType* that_obj = that->AsObject();
|
| + if (this_obj->Width() < that_obj->Width()) return false;
|
| + for (int i = 0; i < that_obj->Width(); ++i) {
|
| + if (!this_obj->Name(i)->Equals(*that_obj->Name(i)) ||
|
| + !this_obj->Property(i)->Equals(that_obj->Property(i)))
|
| + return false;
|
| + }
|
| + return true;
|
| + }
|
| UNREACHABLE();
|
| return false;
|
| }
|
|
|