summaryrefslogtreecommitdiffstats
path: root/devtools/client/debugger/new/test/mochitest/examples/frames.js
blob: 0f031582e4e1657173b9a53ee09585b12fc0bc69 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
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);
}