summaryrefslogtreecommitdiffstats
path: root/js/src/jit-test/tests/basic/setCall.js
blob: 0e4950e1c292cfd699187bb9af2aa4469d51ff96 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
function f() {
  var x = 11;

  function g() {
    var y = 12;

    function h() {
      for (var i = 0; i < 5; ++i) {
	y = 4;
	x = i * 2;
      }
    }
    h();

    assertEq(y, 4);
  }
  g();

  assertEq(x, 8);
} 

f();