summaryrefslogtreecommitdiffstats
path: root/js/src/jit-test/tests/ion/bug875452.js
blob: 27a1de4ac7e165e2db2d4f4c4afd5c210ebf8069 (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
25
26
// |jit-test| --ion-eager

function causeBreak(t, n, r) {
    gcPreserveCode();
    gc();
}

function centralizeGetProp(p)
{
    p.someProp;
}

var handler = {};

function test() {
    var p = new Proxy({}, handler);

    var count = 5;
    for (var i = 0; i < count; i++) {
        centralizeGetProp(p);
    }
    handler.get = causeBreak;
    centralizeGetProp(p);
}

test();