summaryrefslogtreecommitdiffstats
path: root/js/src/jit-test/tests/debug/bug1252464.js
blob: e93e5ec32f5fb56c34bf5913e8dd7854b0183615 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
// |jit-test| error: ReferenceError

g = newGlobal({newCompartment: true});
dbg = Debugger(g);
hits = 0;
dbg.onNewScript = function () { return hits++; };
assertEq(g.eval("eval('2 + 3')"), 5);
this.gczeal(hits,1);
dbg = Debugger(g);
g.h = function () {
  var env = dbg.getNewestFrame().environment;
  dbg =  0;
  assertThrowsInstanceOf;
}
g.eval("h()");