summaryrefslogtreecommitdiffstats
path: root/js/src/jit-test/tests/auto-regress/bug678090.js
blob: a9fa365ccabc3d8a0fb9389771009487d936f5a2 (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
// |jit-test| error:ReferenceError

// Binary: cache/js-dbg-64-609f37c36bd7-linux
// Flags: -j -m -a
//

function toSource(arr) {
  for (i=0; i<len; i++) {}
}
test();
function test() {
  function gen() {
    var c = test;
    try {
      yield c;
    } finally {
      this.toSource();
    }
  }
  var iter = gen();
  for (i in iter) {
    500();
  }
}