Incorrect scoping for default parameters
Via #36 (closed). This is a tricky situation:
(function(x, f = () => x) {
var x;
var y = x;
x = 2;
return [x, y, f()];
})(1)
It should yield [2, 1, 1]
, but current output yields [2, 1, 2]
.
Via #36 (closed). This is a tricky situation:
(function(x, f = () => x) {
var x;
var y = x;
x = 2;
return [x, y, f()];
})(1)
It should yield [2, 1, 1]
, but current output yields [2, 1, 2]
.