OLD | NEW |
1 // Copyright 2013 the V8 project authors. All rights reserved. | 1 // Copyright 2013 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 (function(global, utils) { | 5 (function(global, utils) { |
6 | 6 |
7 "use strict"; | 7 "use strict"; |
8 | 8 |
9 %CheckIsBootstrapping(); | 9 %CheckIsBootstrapping(); |
10 | 10 |
11 // ----------------------------------------------------------------------- | 11 // ----------------------------------------------------------------------- |
12 // Imports | 12 // Imports |
13 | 13 |
14 var arrayIterationKindSymbol = | 14 var arrayIterationKindSymbol = |
15 utils.ImportNow("array_iteration_kind_symbol"); | 15 utils.ImportNow("array_iteration_kind_symbol"); |
16 var arrayIteratorNextIndexSymbol = | 16 var arrayIteratorNextIndexSymbol = |
17 utils.ImportNow("array_iterator_next_symbol"); | 17 utils.ImportNow("array_iterator_next_symbol"); |
18 var arrayIteratorObjectSymbol = | 18 var arrayIteratorObjectSymbol = |
19 utils.ImportNow("array_iterator_object_symbol"); | 19 utils.ImportNow("array_iterator_object_symbol"); |
20 var GlobalArray = global.Array; | 20 var GlobalArray = global.Array; |
21 var IteratorPrototype = utils.ImportNow("IteratorPrototype"); | 21 var IteratorPrototype = utils.ImportNow("IteratorPrototype"); |
22 var iteratorSymbol = utils.ImportNow("iterator_symbol"); | 22 var iteratorSymbol = utils.ImportNow("iterator_symbol"); |
23 var MakeTypeError; | 23 var MakeTypeError; |
24 var toStringTagSymbol = utils.ImportNow("to_string_tag_symbol"); | 24 var toStringTagSymbol = utils.ImportNow("to_string_tag_symbol"); |
25 var GlobalTypedArray = %object_get_prototype_of(global.Uint8Array); | 25 var GlobalTypedArray = global.Uint8Array.__proto__; |
26 | 26 |
27 utils.Import(function(from) { | 27 utils.Import(function(from) { |
28 MakeTypeError = from.MakeTypeError; | 28 MakeTypeError = from.MakeTypeError; |
29 }) | 29 }) |
30 | 30 |
31 // ----------------------------------------------------------------------- | 31 // ----------------------------------------------------------------------- |
32 | 32 |
33 function ArrayIterator() {} | 33 function ArrayIterator() {} |
34 | 34 |
35 | 35 |
(...skipping 126 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
162 // ------------------------------------------------------------------- | 162 // ------------------------------------------------------------------- |
163 // Exports | 163 // Exports |
164 | 164 |
165 utils.Export(function(to) { | 165 utils.Export(function(to) { |
166 to.ArrayValues = ArrayValues; | 166 to.ArrayValues = ArrayValues; |
167 }); | 167 }); |
168 | 168 |
169 %InstallToContext(["array_values_iterator", ArrayValues]); | 169 %InstallToContext(["array_values_iterator", ArrayValues]); |
170 | 170 |
171 }) | 171 }) |
OLD | NEW |