summaryrefslogtreecommitdiffstats
path: root/js/src/jit-test/tests/basic/bug560234.js
blob: dc2956a76b5fa8cb4af40264520f7bfce863cce6 (plain)
1
2
3
4
5
6
7
8
9
10
function test() {
    var a = ['x', '', '', '', '', '', '', 'x'];
    var b = '';
    for (var i = 0; i < a.length; i++) {
        (function() {
            a[i].replace(/x/, function() { return b; });
        }());
    }
}
test();  // should NOT get a ReferenceError for b on trace