aboutsummaryrefslogtreecommitdiff
path: root/lib/compress.js
diff options
context:
space:
mode:
authorAlex Lam S.L <alexlamsl@gmail.com>2018-02-03 07:58:43 +0800
committerGitHub <noreply@github.com>2018-02-03 07:58:43 +0800
commit7e13c0db4034d2c28e36473a3add915de1813844 (patch)
tree0788e4fc0c87cee3336701e59c39f19ea099e8da /lib/compress.js
parente6a2e9e4d08b73c327e95bcd4da923f9404788d0 (diff)
downloadtracifyjs-7e13c0db4034d2c28e36473a3add915de1813844.tar.gz
tracifyjs-7e13c0db4034d2c28e36473a3add915de1813844.zip
handle `break` & `continue` in `collapse_vars` (#2875)
fixes #2873
Diffstat (limited to 'lib/compress.js')
-rw-r--r--lib/compress.js1
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/compress.js b/lib/compress.js
index 6f9d64f9..993092a0 100644
--- a/lib/compress.js
+++ b/lib/compress.js
@@ -968,6 +968,7 @@ merge(Compressor.prototype, {
|| node instanceof AST_Call && lhs instanceof AST_PropAccess && lhs.equivalent_to(node.expression)
|| node instanceof AST_Debugger
|| node instanceof AST_IterationStatement && !(node instanceof AST_For)
+ || node instanceof AST_LoopControl
|| node instanceof AST_Try
|| node instanceof AST_With
|| parent instanceof AST_For && node !== parent.init