From 94785e8e14efaba6b2d8cbe61f183cf920cdb329 Mon Sep 17 00:00:00 2001 From: "Alex Lam S.L" Date: Tue, 31 Dec 2019 09:57:35 +0800 Subject: fix corner case in `booleans` (#3659) fixes #3658 --- test/compress/booleans.js | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) (limited to 'test') diff --git a/test/compress/booleans.js b/test/compress/booleans.js index a036a1d0..e1fa1a4f 100644 --- a/test/compress/booleans.js +++ b/test/compress/booleans.js @@ -110,3 +110,24 @@ issue_2737_2: { } expect_stdout: "PASS" } + +issue_3658: { + options = { + booleans: true, + evaluate: true, + reduce_vars: true, + } + input: { + console.log(function f() { + console || f(); + return "PASS"; + }()); + } + expect: { + console.log(function f() { + console || f(); + return "PASS"; + }()); + } + expect_stdout: "PASS" +} -- cgit v1.2.3