OLD | NEW |
1 // Copyright 2011 the V8 project authors. All rights reserved. | 1 // Copyright 2011 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_LIST_H_ | 5 #ifndef V8_LIST_H_ |
6 #define V8_LIST_H_ | 6 #define V8_LIST_H_ |
7 | 7 |
8 #include <algorithm> | 8 #include <algorithm> |
9 | 9 |
10 #include "src/checks.h" | 10 #include "src/checks.h" |
11 #include "src/utils.h" | 11 #include "src/vector.h" |
12 | 12 |
13 namespace v8 { | 13 namespace v8 { |
14 namespace internal { | 14 namespace internal { |
15 | 15 |
16 template<typename T> class Vector; | 16 template<typename T> class Vector; |
17 | 17 |
18 // ---------------------------------------------------------------------------- | 18 // ---------------------------------------------------------------------------- |
19 // The list is a template for very light-weight lists. We are not | 19 // The list is a template for very light-weight lists. We are not |
20 // using the STL because we want full control over space and speed of | 20 // using the STL because we want full control over space and speed of |
21 // the code. This implementation is based on code by Robert Griesemer | 21 // the code. This implementation is based on code by Robert Griesemer |
(...skipping 204 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
226 int SortedListBSearch(const List<T>& list, P cmp); | 226 int SortedListBSearch(const List<T>& list, P cmp); |
227 template <typename T> | 227 template <typename T> |
228 int SortedListBSearch(const List<T>& list, T elem); | 228 int SortedListBSearch(const List<T>& list, T elem); |
229 | 229 |
230 | 230 |
231 } // namespace internal | 231 } // namespace internal |
232 } // namespace v8 | 232 } // namespace v8 |
233 | 233 |
234 | 234 |
235 #endif // V8_LIST_H_ | 235 #endif // V8_LIST_H_ |
OLD | NEW |