OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 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 #ifndef V8_PROPERTY_DETAILS_H_ | 5 #ifndef V8_PROPERTY_DETAILS_H_ |
6 #define V8_PROPERTY_DETAILS_H_ | 6 #define V8_PROPERTY_DETAILS_H_ |
7 | 7 |
8 #include "include/v8.h" | 8 #include "include/v8.h" |
9 #include "src/allocation.h" | 9 #include "src/allocation.h" |
10 #include "src/utils.h" | 10 #include "src/utils.h" |
(...skipping 236 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
247 PropertyDetails(PropertyAttributes attributes, | 247 PropertyDetails(PropertyAttributes attributes, |
248 PropertyType type, | 248 PropertyType type, |
249 Representation representation, | 249 Representation representation, |
250 int field_index = 0) { | 250 int field_index = 0) { |
251 value_ = TypeField::encode(type) | 251 value_ = TypeField::encode(type) |
252 | AttributesField::encode(attributes) | 252 | AttributesField::encode(attributes) |
253 | RepresentationField::encode(EncodeRepresentation(representation)) | 253 | RepresentationField::encode(EncodeRepresentation(representation)) |
254 | FieldIndexField::encode(field_index); | 254 | FieldIndexField::encode(field_index); |
255 } | 255 } |
256 | 256 |
257 PropertyDetails(PropertyAttributes attributes, PropertyKind kind, | 257 PropertyDetails(PropertyKind kind, PropertyAttributes attributes, |
258 PropertyLocation location, Representation representation, | 258 PropertyLocation location, Representation representation, |
259 int field_index = 0) { | 259 int field_index = 0) { |
260 value_ = KindField::encode(kind) | LocationField::encode(location) | | 260 value_ = KindField::encode(kind) | LocationField::encode(location) | |
261 AttributesField::encode(attributes) | | 261 AttributesField::encode(attributes) | |
262 RepresentationField::encode(EncodeRepresentation(representation)) | | 262 RepresentationField::encode(EncodeRepresentation(representation)) | |
263 FieldIndexField::encode(field_index); | 263 FieldIndexField::encode(field_index); |
264 } | 264 } |
265 | 265 |
266 static PropertyDetails Empty( | 266 static PropertyDetails Empty( |
267 PropertyCellType cell_type = PropertyCellType::kNoCell) { | 267 PropertyCellType cell_type = PropertyCellType::kNoCell) { |
(...skipping 125 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
393 }; | 393 }; |
394 | 394 |
395 | 395 |
396 std::ostream& operator<<(std::ostream& os, | 396 std::ostream& operator<<(std::ostream& os, |
397 const PropertyAttributes& attributes); | 397 const PropertyAttributes& attributes); |
398 std::ostream& operator<<(std::ostream& os, const PropertyDetails& details); | 398 std::ostream& operator<<(std::ostream& os, const PropertyDetails& details); |
399 } // namespace internal | 399 } // namespace internal |
400 } // namespace v8 | 400 } // namespace v8 |
401 | 401 |
402 #endif // V8_PROPERTY_DETAILS_H_ | 402 #endif // V8_PROPERTY_DETAILS_H_ |
OLD | NEW |