summaryrefslogtreecommitdiffstats
path: root/js/src/jit-test/tests/debug/onExceptionUnwind-13.js
blob: 611bf4c9dd37a337bb00bc530fd8ff381c35ce9d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
// |jit-test| error: 4
//
// Test that we can handle doing debug mode OSR from onExceptionUnwind when
// settling on a pc without a Baseline ICEntry.

var g = newGlobal();
var dbg = new Debugger(g);
dbg.onExceptionUnwind = function () {};

g.eval("" + function f(y) {
  if (y > 0) {
    throw 4;
  }
});
g.eval("f(0)");
g.eval("f(1)");