michael@0: // After an onExceptionUnwind hook throws, if uncaughtExceptionHook returns michael@0: // undefined, the original exception continues to propagate. michael@0: michael@0: var g = newGlobal(); michael@0: var dbg = new Debugger(g); michael@0: var log = ''; michael@0: dbg.onExceptionUnwind = function () { log += "1"; throw new Error("oops"); }; michael@0: dbg.uncaughtExceptionHook = function () { log += "2"; }; michael@0: michael@0: g.eval("var x = new Error('oops');"); michael@0: g.eval("try { throw x; } catch (exc) { assertEq(exc, x); }"); michael@0: assertEq(log, "12");