OLD | NEW |
1 // Copyright 2015 the V8 project authors. All rights reserved. | 1 // Copyright 2015 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/assert-scope.h" | 10 #include "src/assert-scope.h" |
(...skipping 2832 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2843 kReloadLengthAfterAllocation, | 2843 kReloadLengthAfterAllocation, |
2844 }; | 2844 }; |
2845 static Handle<ArrayList> Add(Handle<ArrayList> array, Handle<Object> obj, | 2845 static Handle<ArrayList> Add(Handle<ArrayList> array, Handle<Object> obj, |
2846 AddMode mode = kNone); | 2846 AddMode mode = kNone); |
2847 static Handle<ArrayList> Add(Handle<ArrayList> array, Handle<Object> obj1, | 2847 static Handle<ArrayList> Add(Handle<ArrayList> array, Handle<Object> obj1, |
2848 Handle<Object> obj2, AddMode = kNone); | 2848 Handle<Object> obj2, AddMode = kNone); |
2849 inline int Length(); | 2849 inline int Length(); |
2850 inline void SetLength(int length); | 2850 inline void SetLength(int length); |
2851 inline Object* Get(int index); | 2851 inline Object* Get(int index); |
2852 inline Object** Slot(int index); | 2852 inline Object** Slot(int index); |
2853 inline void Set(int index, Object* obj); | 2853 inline void Set(int index, Object* obj, |
| 2854 WriteBarrierMode mode = UPDATE_WRITE_BARRIER); |
2854 inline void Clear(int index, Object* undefined); | 2855 inline void Clear(int index, Object* undefined); |
2855 bool IsFull(); | 2856 bool IsFull(); |
2856 DECLARE_CAST(ArrayList) | 2857 DECLARE_CAST(ArrayList) |
2857 | 2858 |
2858 private: | 2859 private: |
2859 static Handle<ArrayList> EnsureSpace(Handle<ArrayList> array, int length); | 2860 static Handle<ArrayList> EnsureSpace(Handle<ArrayList> array, int length); |
2860 static const int kLengthIndex = 0; | 2861 static const int kLengthIndex = 0; |
2861 static const int kFirstIndex = 1; | 2862 static const int kFirstIndex = 1; |
2862 DISALLOW_IMPLICIT_CONSTRUCTORS(ArrayList); | 2863 DISALLOW_IMPLICIT_CONSTRUCTORS(ArrayList); |
2863 }; | 2864 }; |
(...skipping 7933 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
10797 } | 10798 } |
10798 return value; | 10799 return value; |
10799 } | 10800 } |
10800 }; | 10801 }; |
10801 | 10802 |
10802 | 10803 |
10803 } // NOLINT, false-positive due to second-order macros. | 10804 } // NOLINT, false-positive due to second-order macros. |
10804 } // NOLINT, false-positive due to second-order macros. | 10805 } // NOLINT, false-positive due to second-order macros. |
10805 | 10806 |
10806 #endif // V8_OBJECTS_H_ | 10807 #endif // V8_OBJECTS_H_ |
OLD | NEW |