js/src/jit-test/tests/debug/onEnterFrame-07.js

Thu, 22 Jan 2015 13:21:57 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Thu, 22 Jan 2015 13:21:57 +0100
branch
TOR_BUG_9701
changeset 15
b8a032363ba2
permissions
-rw-r--r--

Incorporate requested changes from Mozilla in review:
https://bugzilla.mozilla.org/show_bug.cgi?id=1123480#c6

     1 var g = newGlobal();
     2 var dbg = new Debugger(g);
     3 var visibleFrames = 0;
     4 dbg.onEnterFrame = function (frame) {
     5   print("> " + frame.script.url);
     6   visibleFrames++;
     7 }
     9 g.eval("(" + function iife() {
    10   [1].forEach(function noop() {});
    11   for (let x of [1]) {}
    12 } + ")()");
    14 // 1 for eval, 1 for iife(), 1 for noop()
    15 assertEq(visibleFrames, 3);

mercurial