aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorAlex Lam S.L <alexlamsl@gmail.com>2020-01-16 01:51:37 +0800
committerGitHub <noreply@github.com>2020-01-16 01:51:37 +0800
commit41a6eb892a89eef1a6a238e2ce5bc36b86cf4fee (patch)
tree006cfe5aa74b4f87b94581d4b55b8621f18ad2b9 /lib
parent91d87ae6633ba66706df32e8b955061c0e9d788f (diff)
downloadtracifyjs-41a6eb892a89eef1a6a238e2ce5bc36b86cf4fee.tar.gz
tracifyjs-41a6eb892a89eef1a6a238e2ce5bc36b86cf4fee.zip
fix corner case in `evaluate` (#3685)
fixes #3684
Diffstat (limited to 'lib')
-rw-r--r--lib/compress.js3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/compress.js b/lib/compress.js
index ffa5a644..a3baa7b1 100644
--- a/lib/compress.js
+++ b/lib/compress.js
@@ -2497,9 +2497,10 @@ merge(Compressor.prototype, {
&& (!(right instanceof AST_Constant) || right.value == 0);
case "&&":
case "||":
- case "*":
return left.is_negative_zero() || right.is_negative_zero();
+ case "*":
case "/":
+ return true;
case "%":
return left.is_negative_zero();
default: