Merge Chromium + Blink git repositories
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / fast / js / vardecl-preserve-parameters.html
blob12d83e4811518d8cbca60c605c80b3891c1d3d83
1 <p>This test verifies var declarations inside a function don't stomp function arguments.</p>
3 <pre id="console"></pre>
5 <script>
6 if (window.testRunner)
7 testRunner.dumpAsText();
9 function log(s)
11 document.getElementById("console").appendChild(document.createTextNode(s + "\n"));
14 function f(x)
16 var x;
17 if (x == 1)
18 log("PASS: x should be 1 and is.");
19 else
20 log("FAIL: x should be 1 but instead is " + x + ".");
22 f(1);
23 </script>