OLD | NEW |
1 // Copyright 2014 the V8 project authors. All rights reserved. | 1 // Copyright 2014 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 // Flags: --harmony --expose-debug-as=debug | 5 // Flags: --harmony-modules --expose-debug-as=debug |
6 | 6 |
7 (function () { // Scope for utility functions. | 7 (function () { // Scope for utility functions. |
8 escaping_function = function(object) { | 8 escaping_function = function(object) { |
9 // Argument must not be null or undefined. | 9 // Argument must not be null or undefined. |
10 var string = Object.prototype.toString.call(object); | 10 var string = Object.prototype.toString.call(object); |
11 // String has format [object <ClassName>]. | 11 // String has format [object <ClassName>]. |
12 return string.substring(8, string.length - 1); | 12 return string.substring(8, string.length - 1); |
13 } | 13 } |
14 })(); | 14 })(); |
15 | 15 |
16 module B { | 16 module B { |
17 var stuff = 3 | 17 var stuff = 3 |
18 } | 18 } |
19 | 19 |
20 var __v_0 = {}; | 20 var __v_0 = {}; |
21 var __v_4 = debug.MakeMirror(__v_0); | 21 var __v_4 = debug.MakeMirror(__v_0); |
22 print(__v_4.referencedBy().length); // core dump here if not fixed. | 22 print(__v_4.referencedBy().length); // core dump here if not fixed. |
OLD | NEW |