blob: d2d4b93f3a0fe0ef9d23658b8ddb5b2467a771ca [file] [log] [blame]
function assert(b, m) {
if (!b)
throw new Error(m);
}
function test7() {
function foo(o, i) {
return o[i];
}
noInline(foo);
let s1 = Symbol();
let s2 = Symbol();
let o = {[s1]: 42, [s2]: 43};
let start = Date.now();
for (let i = 0; i < 10000000; ++i) {
assert(foo(o, s1) === 42);
assert(foo(o, s2) === 43);
}
}
test7();