aboutsummaryrefslogtreecommitdiff
path: root/lib/compress.js
diff options
context:
space:
mode:
Diffstat (limited to 'lib/compress.js')
-rw-r--r--lib/compress.js5
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/compress.js b/lib/compress.js
index 814e9a8b..6af086f7 100644
--- a/lib/compress.js
+++ b/lib/compress.js
@@ -312,8 +312,11 @@ merge(Compressor.prototype, {
|| node instanceof AST_Try
|| node instanceof AST_With
|| node instanceof AST_IterationStatement
+ || (parent instanceof AST_Binary
+ && (parent.operator == "&&" || parent.operator == "||")
+ && node === parent.right)
|| (parent instanceof AST_Switch && node !== parent.expression)) {
- return unwind = true, node;
+ return side_effects_encountered = unwind = true, node;
}
},
function postorder(node) {