js/src/jit-test/tests/basic/builtinLocals.js

changeset 0
6474c204b198
equal deleted inserted replaced
-1:000000000000 0:baf7054e240e
1
2 /* Resolve 'arguments' and the name of the function itself in the presence of such local variables. */
3
4 function f() {
5 return typeof arguments;
6 function arguments() {
7 return 7;
8 }
9 }
10 assertEq(f(), "function");
11
12 function g() {
13 var arguments = 0;
14 return typeof arguments;
15 }
16 assertEq(g(), "number");
17
18 function h() {
19 return typeof h;
20 function h() {
21 return 7;
22 }
23 }
24 assertEq(h(), "function");
25
26 function i() {
27 return typeof i;
28 var i;
29 }
30 assertEq(i(), "undefined");
31
32 function j() {
33 return typeof j;
34 }
35 assertEq(j(), "function");

mercurial