OLD | NEW |
1 // Copyright 2015 the V8 project authors. All rights reserved. | 1 // Copyright 2015 the V8 project authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "src/objects.h" | 5 #include "src/objects.h" |
6 | 6 |
7 #include <cmath> | 7 #include <cmath> |
8 #include <iomanip> | 8 #include <iomanip> |
9 #include <memory> | 9 #include <memory> |
10 #include <sstream> | 10 #include <sstream> |
(...skipping 9434 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
9445 } | 9445 } |
9446 | 9446 |
9447 | 9447 |
9448 bool DescriptorArray::IsEqualUpTo(DescriptorArray* desc, int nof_descriptors) { | 9448 bool DescriptorArray::IsEqualUpTo(DescriptorArray* desc, int nof_descriptors) { |
9449 for (int i = 0; i < nof_descriptors; i++) { | 9449 for (int i = 0; i < nof_descriptors; i++) { |
9450 if (GetKey(i) != desc->GetKey(i) || GetValue(i) != desc->GetValue(i)) { | 9450 if (GetKey(i) != desc->GetKey(i) || GetValue(i) != desc->GetValue(i)) { |
9451 return false; | 9451 return false; |
9452 } | 9452 } |
9453 PropertyDetails details = GetDetails(i); | 9453 PropertyDetails details = GetDetails(i); |
9454 PropertyDetails other_details = desc->GetDetails(i); | 9454 PropertyDetails other_details = desc->GetDetails(i); |
9455 if (details.type() != other_details.type() || | 9455 if (details.kind() != other_details.kind() || |
| 9456 details.location() != other_details.location() || |
9456 !details.representation().Equals(other_details.representation())) { | 9457 !details.representation().Equals(other_details.representation())) { |
9457 return false; | 9458 return false; |
9458 } | 9459 } |
9459 } | 9460 } |
9460 return true; | 9461 return true; |
9461 } | 9462 } |
9462 | 9463 |
9463 | 9464 |
9464 Handle<Map> Map::CopyReplaceDescriptor(Handle<Map> map, | 9465 Handle<Map> Map::CopyReplaceDescriptor(Handle<Map> map, |
9465 Handle<DescriptorArray> descriptors, | 9466 Handle<DescriptorArray> descriptors, |
(...skipping 10405 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
19871 // depend on this. | 19872 // depend on this. |
19872 return DICTIONARY_ELEMENTS; | 19873 return DICTIONARY_ELEMENTS; |
19873 } | 19874 } |
19874 DCHECK_LE(kind, LAST_ELEMENTS_KIND); | 19875 DCHECK_LE(kind, LAST_ELEMENTS_KIND); |
19875 return kind; | 19876 return kind; |
19876 } | 19877 } |
19877 } | 19878 } |
19878 | 19879 |
19879 } // namespace internal | 19880 } // namespace internal |
19880 } // namespace v8 | 19881 } // namespace v8 |
OLD | NEW |