Index: src/objects.h |
diff --git a/src/objects.h b/src/objects.h |
index ef3cd34a9a78a28207a9936b8447bf65a9806533..78291a6c773bbd88b64969e04e0cef7deec0156d 100644 |
--- a/src/objects.h |
+++ b/src/objects.h |
@@ -168,6 +168,12 @@ enum ContextualMode { |
}; |
+enum MutableMode { |
+ MUTABLE, |
+ IMMUTABLE |
+}; |
+ |
+ |
static const int kGrowICDelta = STORE_AND_GROW_NO_TRANSITION - |
STANDARD_STORE; |
STATIC_ASSERT(STANDARD_STORE == 0); |
@@ -352,6 +358,7 @@ const int kStubMinorKeyBits = kBitsPerInt - kSmiTagSize - kStubMajorKeyBits; |
V(PROPERTY_CELL_TYPE) \ |
\ |
V(HEAP_NUMBER_TYPE) \ |
+ V(MUTABLE_HEAP_NUMBER_TYPE) \ |
V(FOREIGN_TYPE) \ |
V(BYTE_ARRAY_TYPE) \ |
V(FREE_SPACE_TYPE) \ |
@@ -680,6 +687,7 @@ enum InstanceType { |
// "Data", objects that cannot contain non-map-word pointers to heap |
// objects. |
HEAP_NUMBER_TYPE, |
+ MUTABLE_HEAP_NUMBER_TYPE, |
FOREIGN_TYPE, |
BYTE_ARRAY_TYPE, |
FREE_SPACE_TYPE, |
@@ -900,6 +908,7 @@ template <class C> inline bool Is(Object* obj); |
#define HEAP_OBJECT_TYPE_LIST(V) \ |
V(HeapNumber) \ |
+ V(MutableHeapNumber) \ |
V(Name) \ |
V(UniqueName) \ |
V(String) \ |
@@ -1427,7 +1436,7 @@ class Object { |
} else if (FLAG_track_fields && representation.IsSmi()) { |
return IsSmi(); |
} else if (FLAG_track_double_fields && representation.IsDouble()) { |
- return IsNumber(); |
+ return IsMutableHeapNumber() || IsNumber(); |
} else if (FLAG_track_heap_object_fields && representation.IsHeapObject()) { |
return IsHeapObject(); |
} |
@@ -1440,6 +1449,10 @@ class Object { |
Handle<Object> object, |
Representation representation); |
+ inline static Handle<Object> WrapForRead(Isolate* isolate, |
+ Handle<Object> object, |
+ Representation representation); |
+ |
// Returns true if the object is of the correct type to be used as a |
// implementation of a JSObject's elements. |
inline bool HasValidElements(); |