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 var $regexpLastMatchInfoOverride; | 5 var $regexpLastMatchInfoOverride; |
6 | 6 |
7 (function(global, utils) { | 7 (function(global, utils) { |
8 | 8 |
9 %CheckIsBootstrapping(); | 9 %CheckIsBootstrapping(); |
10 | 10 |
11 // ------------------------------------------------------------------- | 11 // ------------------------------------------------------------------- |
12 // Imports | 12 // Imports |
13 | 13 |
14 var FLAG_harmony_regexps; | 14 var FLAG_harmony_regexps; |
15 var FLAG_harmony_unicode_regexps; | 15 var FLAG_harmony_unicode_regexps; |
16 var GlobalRegExp = global.RegExp; | 16 var GlobalRegExp = global.RegExp; |
17 var InternalPackedArray = utils.InternalPackedArray; | 17 var InternalPackedArray = utils.InternalPackedArray; |
18 var ToNumber; | |
19 | |
20 utils.Import(function(from) { | |
21 ToNumber = from.ToNumber; | |
22 }); | |
23 | 18 |
24 utils.ImportFromExperimental(function(from) { | 19 utils.ImportFromExperimental(function(from) { |
25 FLAG_harmony_regexps = from.FLAG_harmony_regexps; | 20 FLAG_harmony_regexps = from.FLAG_harmony_regexps; |
26 FLAG_harmony_unicode_regexps = from.FLAG_harmony_unicode_regexps; | 21 FLAG_harmony_unicode_regexps = from.FLAG_harmony_unicode_regexps; |
27 }); | 22 }); |
28 | 23 |
29 // ------------------------------------------------------------------- | 24 // ------------------------------------------------------------------- |
30 | 25 |
31 // Property of the builtins object for recording the result of the last | 26 // Property of the builtins object for recording the result of the last |
32 // regexp match. The property RegExpLastMatchInfo includes the matchIndices | 27 // regexp match. The property RegExpLastMatchInfo includes the matchIndices |
(...skipping 421 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
454 // Exports | 449 // Exports |
455 | 450 |
456 utils.Export(function(to) { | 451 utils.Export(function(to) { |
457 to.RegExpExec = DoRegExpExec; | 452 to.RegExpExec = DoRegExpExec; |
458 to.RegExpExecNoTests = RegExpExecNoTests; | 453 to.RegExpExecNoTests = RegExpExecNoTests; |
459 to.RegExpLastMatchInfo = RegExpLastMatchInfo; | 454 to.RegExpLastMatchInfo = RegExpLastMatchInfo; |
460 to.RegExpTest = RegExpTest; | 455 to.RegExpTest = RegExpTest; |
461 }); | 456 }); |
462 | 457 |
463 }) | 458 }) |
OLD | NEW |