enhance side_effects & unused (#5181)

This commit is contained in:
Alex Lam S.L
2021-11-22 03:14:28 +00:00
committed by GitHub
parent 839f4361f4
commit 1e3ca4c6f7
4 changed files with 101 additions and 16 deletions

View File

@@ -1044,13 +1044,13 @@ issue_5100_1: {
}
expect: {
var a;
[ {
({
p: {},
...a
} ] = [ {
} = [ {
p: [ a = 42["q"] ],
r: "PASS",
} ];
} ][0]);
console.log(a.r);
}
expect_stdout: "PASS"
@@ -1077,12 +1077,12 @@ issue_5100_2: {
}
expect: {
var a;
[ {
({
p: {},
...a
} ] = [ {
} = [ {
p: [ console.log("PASS"), a = 42["q"] ],
} ];
} ][0]);
}
expect_stdout: "PASS"
node_version: ">=10"