summaryrefslogtreecommitdiffstats
path: root/js/src/jit-test/tests/modules/bug-1245518.js
blob: 857451cabdf855d6d3f6693fe2588e08212bd4a5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
evalInFrame = function(global) {
  dbgGlobal = newGlobal({newCompartment: true});
  dbg = new dbgGlobal.Debugger();
  return function(upCount, code) {
    dbg.addDebuggee(global);
    frame = dbg.getNewestFrame().older;
    frame.eval(code);
  }
}(this);
m = parseModule(`
  function g() { return this.hours = 0; }
  evalInFrame.call(0, 0, "g()")
`);
moduleLink(m);
moduleEvaluate(m);