diff options
Diffstat (limited to 'devtools/client/debugger/new/test/mochitest/examples/frames.js')
-rw-r--r-- | devtools/client/debugger/new/test/mochitest/examples/frames.js | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/devtools/client/debugger/new/test/mochitest/examples/frames.js b/devtools/client/debugger/new/test/mochitest/examples/frames.js new file mode 100644 index 000000000..0f031582e --- /dev/null +++ b/devtools/client/debugger/new/test/mochitest/examples/frames.js @@ -0,0 +1,24 @@ +function recurseA(i) { + if (i == 20) { + debugger; + return; + } + + // down into the rabbit hole we go + return (i % 2) ? recurseA(++i) : recurseB(++i); +} + +function recurseB(i) { + if (i == 20) { + debugger; + return; + } + + // down into the rabbit hole we go + return (i % 2) ? recurseA(++i) : recurseB(++i); +} + + +window.startRecursion = function() { + return recurseA(0); +} |