diff options
Diffstat (limited to 'test/compress/rests.js')
-rw-r--r-- | test/compress/rests.js | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/test/compress/rests.js b/test/compress/rests.js index 45d8e222..a62e380a 100644 --- a/test/compress/rests.js +++ b/test/compress/rests.js @@ -1069,3 +1069,25 @@ issue_5100_2: { expect_stdout: "PASS" node_version: ">=10" } + +issue_5108: { + options = { + evaluate: true, + reduce_vars: true, + rests: true, + unsafe: true, + unused: true, + } + input: { + console.log(function([ ...[ a ] ]) { + return a; + }([ "PASS", "FAIL" ])); + } + expect: { + console.log(function([]) { + return "PASS"; + }([ "PASS", "FAIL" ])); + } + expect_stdout: "PASS" + node_version: ">=6" +} |