summaryrefslogtreecommitdiffstats
path: root/js/src/jit-test/tests/ion/scalar-replacement-bug1138693.js
blob: 4f98c0d338bd60afa485c7d151d130ac619ac792 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
if (!this.hasOwnProperty("TypedObject"))
  quit();

var T = TypedObject;
var ST = new T.StructType({x:T.int32});
function check(v) {
    return v.toSource();
}
function test() {
    var fake = { toSource: ST.toSource };
    try {
        check(fake);
    } catch (e) {}
}
test();
var uint8 = TypedObject.uint8;
function runTests() {
  uint8.toSource();
}
runTests();
test();