| 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_OBJECTS_H_ | 5 #ifndef V8_OBJECTS_H_ |
| 6 #define V8_OBJECTS_H_ | 6 #define V8_OBJECTS_H_ |
| 7 | 7 |
| 8 #include <iosfwd> | 8 #include <iosfwd> |
| 9 | 9 |
| 10 #include "src/allocation.h" | 10 #include "src/allocation.h" |
| (...skipping 2051 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2062 // Returns the number of elements on this object filtering out elements | 2062 // Returns the number of elements on this object filtering out elements |
| 2063 // with the specified attributes (ignoring interceptors). | 2063 // with the specified attributes (ignoring interceptors). |
| 2064 int GetOwnElementKeys(FixedArray* storage, PropertyAttributes filter); | 2064 int GetOwnElementKeys(FixedArray* storage, PropertyAttributes filter); |
| 2065 // Count and fill in the enumerable elements into storage. | 2065 // Count and fill in the enumerable elements into storage. |
| 2066 // (storage->length() == NumberOfEnumElements()). | 2066 // (storage->length() == NumberOfEnumElements()). |
| 2067 // If storage is NULL, will count the elements without adding | 2067 // If storage is NULL, will count the elements without adding |
| 2068 // them to any storage. | 2068 // them to any storage. |
| 2069 // Returns the number of enumerable elements. | 2069 // Returns the number of enumerable elements. |
| 2070 int GetEnumElementKeys(FixedArray* storage); | 2070 int GetEnumElementKeys(FixedArray* storage); |
| 2071 | 2071 |
| 2072 static Handle<FixedArray> GetEnumPropertyKeys(Handle<JSObject> object, |
| 2073 bool cache_result); |
| 2074 |
| 2072 // Returns a new map with all transitions dropped from the object's current | 2075 // Returns a new map with all transitions dropped from the object's current |
| 2073 // map and the ElementsKind set. | 2076 // map and the ElementsKind set. |
| 2074 static Handle<Map> GetElementsTransitionMap(Handle<JSObject> object, | 2077 static Handle<Map> GetElementsTransitionMap(Handle<JSObject> object, |
| 2075 ElementsKind to_kind); | 2078 ElementsKind to_kind); |
| 2076 static void TransitionElementsKind(Handle<JSObject> object, | 2079 static void TransitionElementsKind(Handle<JSObject> object, |
| 2077 ElementsKind to_kind); | 2080 ElementsKind to_kind); |
| 2078 | 2081 |
| 2079 // Always use this to migrate an object to a new map. | 2082 // Always use this to migrate an object to a new map. |
| 2080 // |expected_additional_properties| is only used for fast-to-slow transitions | 2083 // |expected_additional_properties| is only used for fast-to-slow transitions |
| 2081 // and ignored otherwise. | 2084 // and ignored otherwise. |
| (...skipping 9024 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 11106 } else { | 11109 } else { |
| 11107 value &= ~(1 << bit_position); | 11110 value &= ~(1 << bit_position); |
| 11108 } | 11111 } |
| 11109 return value; | 11112 return value; |
| 11110 } | 11113 } |
| 11111 }; | 11114 }; |
| 11112 | 11115 |
| 11113 } } // namespace v8::internal | 11116 } } // namespace v8::internal |
| 11114 | 11117 |
| 11115 #endif // V8_OBJECTS_H_ | 11118 #endif // V8_OBJECTS_H_ |
| OLD | NEW |