Closed pvginkel closed 9 years ago
The following should output 6, not 7:
6
7
function f(a) { arguments[0]++; with ({a:1}) { var g = function (b) { arguments[0]++; return a + b + eval('1'); } } return g(a + 1); } throw f(1);
The problem is that a is resolved to the argument and is not dynamically resolved to the with local.
a
with
The following should output
6
, not7
:The problem is that
a
is resolved to the argument and is not dynamically resolved to thewith
local.