]> git.saurik.com Git - apple/javascriptcore.git/blame - tests/stress/impure-get-own-property-slot-inline-cache.js
JavaScriptCore-7600.1.4.16.1.tar.gz
[apple/javascriptcore.git] / tests / stress / impure-get-own-property-slot-inline-cache.js
CommitLineData
81345200
A
1
2
3var ig = createImpureGetter(null);
4ig.x = 42;
5
6var foo = function(o) {
7 return o.x;
8};
9
10noInline(foo);
11
12for (var i = 0; i < 10000; ++i)
13 foo(ig);
14
15setImpureGetterDelegate(ig, {x:"x"});
16
17if (foo(ig) !== "x")
18 throw new Error("Incorrect result!");