• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
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
3// found in the LICENSE file.
4
5// Flags: --harmony-modules --expose-debug-as=debug
6
7(function () {  // Scope for utility functions.
8  escaping_function = function(object) {
9    // Argument must not be null or undefined.
10    var string = Object.prototype.toString.call(object);
11    // String has format [object <ClassName>].
12    return string.substring(8, string.length - 1);
13  }
14})();
15
16module B {
17  var stuff = 3
18}
19
20var __v_0 = {};
21var __v_4 = debug.MakeMirror(__v_0);
22print(__v_4.referencedBy().length);  // core dump here if not fixed.
23