]> git.saurik.com Git - apple/javascriptcore.git/blame - tests/stress/arguments-exit-strict-mode-fixed.js
JavaScriptCore-7601.1.46.3.tar.gz
[apple/javascriptcore.git] / tests / stress / arguments-exit-strict-mode-fixed.js
CommitLineData
ed1e77d3
A
1"use strict";
2
3function foo(x) {
4 var tmp = x.f + 1;
5 return tmp + arguments[0].f;
6}
7
8noInline(foo);
9
10for (var i = 0; i < 10000; ++i) {
11 var result = foo({f:i});
12 if (result != i + i + 1)
13 throw "Error: bad result: " + result;
14}
15
16var result = foo({f:4.5});
17if (result != 4.5 + 4.5 + 1)
18 throw "Error: bad result at end: " + result;