From 9703ac3e2b3f209e357acd14692ded1b6ce2b171 Mon Sep 17 00:00:00 2001 From: Tobias Date: Wed, 4 Apr 2018 18:17:36 +0200 Subject: [PATCH] Clear LAST_OUTPUT_FRAGMENT in some places to avoid matching old values --- lib/output.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lib/output.js b/lib/output.js index dca66691..e6ee9118 100644 --- a/lib/output.js +++ b/lib/output.js @@ -298,6 +298,7 @@ function OutputStream(options) { might_need_semicolon = true; } } + LAST_OUTPUT_FRAGMENT = ""; if (!options.beautify) might_need_space = false; @@ -309,6 +310,7 @@ function OutputStream(options) { while (current_line < target_line) { ensure_line_len(); OUTPUT += "\n"; + LAST_OUTPUT_FRAGMENT = ""; current_pos++; current_line++; current_col = 0; @@ -323,6 +325,7 @@ function OutputStream(options) { || ((ch == "+" || ch == "-") && ch == last)) { OUTPUT += " "; + LAST_OUTPUT_FRAGMENT = ""; current_col++; current_pos++; }