diff options
Diffstat (limited to 'test')
-rw-r--r-- | test/compress/functions.js | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/test/compress/functions.js b/test/compress/functions.js index 1be01167..4d753469 100644 --- a/test/compress/functions.js +++ b/test/compress/functions.js @@ -4808,3 +4808,24 @@ issue_4155: { "function", ] } + +issue_4159: { + options = { + collapse_vars: true, + inline: true, + reduce_vars: true, + toplevel: true, + unused: true, + } + input: { + var a = 42, c = function(b) { + (b = a) && console.log(a++, b); + }(c = a); + } + expect: { + var a = 42; + (b = a) && console.log(a++, b); + var b; + } + expect_stdout: "42 42" +} |