summaryrefslogtreecommitdiffstats
path: root/js/src/jit-test/tests/debug/resumption-02.js
blob: 1762d61767266dd505c78027977c31e780549225 (plain)
1
2
3
4
5
6
7
8
9
// Simple {return:} resumption.

var g = newGlobal({newCompartment: true});
var dbg = Debugger(g);
dbg.onDebuggerStatement = function (stack) { return {return: 1234}; };

assertEq(g.eval("debugger; false;"), 1234);
g.eval("function f() { debugger; return 'bad'; }");
assertEq(g.f(), 1234);