fix corner case in merge_vars (#4524)

fixes #4523
This commit is contained in:
Alex Lam S.L
2021-01-08 07:49:14 +00:00
committed by GitHub
parent 7fe8c9150a
commit 553034fe52
2 changed files with 27 additions and 2 deletions

View File

@@ -1527,3 +1527,25 @@ issue_4510_2: {
expect_stdout: "PASS"
node_version: ">=8"
}
issue_4523: {
options = {
merge_vars: true,
}
input: {
console.log(function() {
var a, b;
[ a = b = false ] = [ "FAIL" ];
return b || "PASS";
}());
}
expect: {
console.log(function() {
var a, b;
[ a = b = false ] = [ "FAIL" ];
return b || "PASS";
}());
}
expect_stdout: "PASS"
node_version: ">=6"
}