diff options
author | Richard van Velzen <rvanvelzen@experty.com> | 2015-01-12 17:09:34 +0100 |
---|---|---|
committer | Richard van Velzen <rvanvelzen@experty.com> | 2015-01-12 17:09:34 +0100 |
commit | 42ecd42ac00881f7d540cb08969ce7e2721e30d5 (patch) | |
tree | 8879a10566f02177db66450ffa72d52d7639ff72 /lib | |
parent | a10f6a96d724319f9bb582dab42392b4ef05a0e0 (diff) | |
download | tracifyjs-42ecd42ac00881f7d540cb08969ce7e2721e30d5.tar.gz tracifyjs-42ecd42ac00881f7d540cb08969ce7e2721e30d5.zip |
Replace the correct node when replacing in `void` sequences
Close #611.
Diffstat (limited to 'lib')
-rw-r--r-- | lib/compress.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/compress.js b/lib/compress.js index 1f1d4b50..72e4d92d 100644 --- a/lib/compress.js +++ b/lib/compress.js @@ -1937,7 +1937,7 @@ merge(Compressor.prototype, { if (self.cdr instanceof AST_UnaryPrefix && self.cdr.operator == "void" && !self.cdr.expression.has_side_effects(compressor)) { - self.cdr.operator = self.car; + self.cdr.expression = self.car; return self.cdr; } if (self.cdr instanceof AST_Undefined) { |