Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(425)

Side by Side Diff: src/property-details.h

Issue 2624903003: [runtime] Use PropertyKind/PropertyLocation instead of PropertyType. (Closed)
Patch Set: Addressing comments Created 3 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « src/property-descriptor.cc ('k') | src/runtime/runtime-object.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
57 STATIC_ASSERT(ONLY_CONFIGURABLE == static_cast<PropertyFilter>( 57 STATIC_ASSERT(ONLY_CONFIGURABLE == static_cast<PropertyFilter>(
58 v8::PropertyFilter::ONLY_CONFIGURABLE)); 58 v8::PropertyFilter::ONLY_CONFIGURABLE));
59 STATIC_ASSERT(SKIP_STRINGS == 59 STATIC_ASSERT(SKIP_STRINGS ==
60 static_cast<PropertyFilter>(v8::PropertyFilter::SKIP_STRINGS)); 60 static_cast<PropertyFilter>(v8::PropertyFilter::SKIP_STRINGS));
61 STATIC_ASSERT(SKIP_SYMBOLS == 61 STATIC_ASSERT(SKIP_SYMBOLS ==
62 static_cast<PropertyFilter>(v8::PropertyFilter::SKIP_SYMBOLS)); 62 static_cast<PropertyFilter>(v8::PropertyFilter::SKIP_SYMBOLS));
63 63
64 class Smi; 64 class Smi;
65 class TypeInfo; 65 class TypeInfo;
66 66
67 // Type of properties.
68 // Order of kinds is significant. 67 // Order of kinds is significant.
69 // Must fit in the BitField PropertyDetails::KindField. 68 // Must fit in the BitField PropertyDetails::KindField.
70 enum PropertyKind { kData = 0, kAccessor = 1 }; 69 enum PropertyKind { kData = 0, kAccessor = 1 };
71 70
72
73 // Order of modes is significant. 71 // Order of modes is significant.
74 // Must fit in the BitField PropertyDetails::StoreModeField. 72 // Must fit in the BitField PropertyDetails::LocationField.
75 enum PropertyLocation { kField = 0, kDescriptor = 1 }; 73 enum PropertyLocation { kField = 0, kDescriptor = 1 };
76 74
77 75
78 // Order of properties is significant. 76 // Order of properties is significant.
79 // Must fit in the BitField PropertyDetails::TypeField. 77 // Must fit in the BitField PropertyDetails::TypeField.
80 // A copy of this is in debug/mirrors.js. 78 // A copy of this is in debug/mirrors.js.
81 enum PropertyType { 79 enum PropertyType {
82 DATA = (kField << 1) | kData, 80 DATA = (kField << 1) | kData,
83 DATA_CONSTANT = (kDescriptor << 1) | kData, 81 DATA_CONSTANT = (kDescriptor << 1) | kData,
84 ACCESSOR = (kField << 1) | kAccessor, 82 ACCESSOR = (kField << 1) | kAccessor,
(...skipping 308 matching lines...) Expand 10 before | Expand all | Expand 10 after
393 }; 391 };
394 392
395 393
396 std::ostream& operator<<(std::ostream& os, 394 std::ostream& operator<<(std::ostream& os,
397 const PropertyAttributes& attributes); 395 const PropertyAttributes& attributes);
398 std::ostream& operator<<(std::ostream& os, const PropertyDetails& details); 396 std::ostream& operator<<(std::ostream& os, const PropertyDetails& details);
399 } // namespace internal 397 } // namespace internal
400 } // namespace v8 398 } // namespace v8
401 399
402 #endif // V8_PROPERTY_DETAILS_H_ 400 #endif // V8_PROPERTY_DETAILS_H_
OLDNEW
« no previous file with comments | « src/property-descriptor.cc ('k') | src/runtime/runtime-object.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698