diff options
author | Alex Lam S.L <alexlamsl@gmail.com> | 2017-10-17 22:59:15 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-10-17 22:59:15 +0800 |
commit | 0d2fe8e3efdb096af4044b011dd7e2e463581400 (patch) | |
tree | fcd4095b2c591585ea3bef36d1f0611d0cc66f09 /lib/compress.js | |
parent | f2b9c11e2a0ab3597f798cf85770e24733609b1f (diff) | |
download | tracifyjs-0d2fe8e3efdb096af4044b011dd7e2e463581400.tar.gz tracifyjs-0d2fe8e3efdb096af4044b011dd7e2e463581400.zip |
fix `AST_PropAccess` in `collapse_vars` (take 2) (#2372)
fixes #2364
Diffstat (limited to 'lib/compress.js')
-rw-r--r-- | lib/compress.js | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/compress.js b/lib/compress.js index 3909c65c..488cc6fc 100644 --- a/lib/compress.js +++ b/lib/compress.js @@ -839,8 +839,7 @@ merge(Compressor.prototype, { if (node instanceof AST_Call || node instanceof AST_Exit || node instanceof AST_PropAccess - && (node.has_side_effects(compressor) - || get_symbol(node).name in lvalues) + && (side_effects || node.has_side_effects(compressor)) || node instanceof AST_SymbolRef && (lvalues[node.name] || side_effects && !references_in_scope(node.definition())) |