michael@0: // Clearing a frame's onPop handler works. michael@0: var g = newGlobal(); michael@0: g.eval("function f() { debugger; }"); michael@0: var dbg = new Debugger(g); michael@0: michael@0: var log; michael@0: dbg.onEnterFrame = function handleEnter(f) { michael@0: log += "("; michael@0: f.onPop = function handlePop() { michael@0: assertEq("handlePop was called", "handlePop should never be called"); michael@0: }; michael@0: }; michael@0: dbg.onDebuggerStatement = function handleDebugger(f) { michael@0: log += "d"; michael@0: assertEq(typeof f.onPop, "function"); michael@0: f.onPop = undefined; michael@0: }; michael@0: log = ''; michael@0: g.f(); michael@0: assertEq(log, "(d");