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

Unified Diff: runtime/vm/raw_object.h

Issue 16390002: Make ImmutableArray a sub class of AllStatic. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 7 years, 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « runtime/vm/object.cc ('k') | runtime/vm/raw_object.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/raw_object.h
===================================================================
--- runtime/vm/raw_object.h (revision 23868)
+++ runtime/vm/raw_object.h (working copy)
@@ -60,8 +60,6 @@
V(Bigint) \
V(Double) \
V(Bool) \
- V(Array) \
- V(ImmutableArray) \
V(GrowableObjectArray) \
V(TypedData) \
V(ExternalTypedData) \
@@ -72,6 +70,9 @@
V(Float32x4) \
V(Uint32x4) \
+#define CLASS_LIST_ARRAYS(V) \
+ V(Array) \
+ V(ImmutableArray) \
#define CLASS_LIST_STRINGS(V) \
V(String) \
@@ -96,10 +97,12 @@
#define CLASS_LIST_FOR_HANDLES(V) \
CLASS_LIST_NO_OBJECT_OR_STRING(V) \
+ V(Array) \
V(String)
#define CLASS_LIST_NO_OBJECT(V) \
CLASS_LIST_NO_OBJECT_OR_STRING(V) \
+ CLASS_LIST_ARRAYS(V) \
CLASS_LIST_STRINGS(V)
#define CLASS_LIST(V) \
@@ -1602,9 +1605,9 @@
inline bool RawObject::IsBuiltinListClassId(intptr_t index) {
// Make sure this function is updated when new builtin List types are added.
ASSERT(kImmutableArrayCid == kArrayCid + 1 &&
- kGrowableObjectArrayCid == kArrayCid + 2 &&
- kTypedDataCid == kArrayCid + 3);
- return ((index >= kArrayCid && index < kTypedDataCid) ||
+ kTypedDataCid == kGrowableObjectArrayCid + 1);
+ return ((index >= kArrayCid && index < kImmutableArrayCid) ||
+ (index >= kGrowableObjectArrayCid && index < kTypedDataCid) ||
IsTypedDataClassId(index) ||
IsTypedDataViewClassId(index) ||
IsExternalTypedDataClassId(index));
« no previous file with comments | « runtime/vm/object.cc ('k') | runtime/vm/raw_object.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698