fix corner case in evaluate (#3739)

fixes #3738
This commit is contained in:
Alex Lam S.L
2020-03-01 20:34:31 +00:00
committed by GitHub
parent 3485472866
commit a051846d22
2 changed files with 14 additions and 2 deletions

View File

@@ -2161,3 +2161,16 @@ collapse_vars_regexp: {
"abbb",
]
}
issue_3738: {
options = {
evaluate: true,
}
input: {
console.log(1 / (0 + ([] - 1) % 1));
}
expect: {
console.log(1 / (0 + ([] - 1) % 1));
}
expect_stdout: "Infinity"
}