diff options
Diffstat (limited to '')
-rw-r--r-- | js/src/jit-test/tests/warp/bailout-inline-getter.js | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/js/src/jit-test/tests/warp/bailout-inline-getter.js b/js/src/jit-test/tests/warp/bailout-inline-getter.js new file mode 100644 index 0000000000..86ef1300ec --- /dev/null +++ b/js/src/jit-test/tests/warp/bailout-inline-getter.js @@ -0,0 +1,22 @@ +// |jit-test| --fast-warmup; --no-threads + +var iter = 0; + +class A { + get foo() { + var x = iter; + bailout(); + return x; + } +} + +var a = new A(); +function bar() { + return a.foo; +} + +with ({}) {} +for(var i = 0; i < 100; i++) { + iter = i; + assertEq(bar(), i); +} |