aboutsummaryrefslogtreecommitdiff
path: root/test/compress/dead-code.js
diff options
context:
space:
mode:
Diffstat (limited to 'test/compress/dead-code.js')
-rw-r--r--test/compress/dead-code.js21
1 files changed, 21 insertions, 0 deletions
diff --git a/test/compress/dead-code.js b/test/compress/dead-code.js
index 22eb0d91..5506b95a 100644
--- a/test/compress/dead-code.js
+++ b/test/compress/dead-code.js
@@ -1193,3 +1193,24 @@ self_assignments: {
}
expect_stdout: "PASS 2 PASS PASS"
}
+
+issue_3967: {
+ options = {
+ dead_code: true,
+ }
+ input: {
+ var a = "FAIL";
+ try {
+ a = 0 in (a = "PASS");
+ } catch (e) {}
+ console.log(a);
+ }
+ expect: {
+ var a = "FAIL";
+ try {
+ a = 0 in (a = "PASS");
+ } catch (e) {}
+ console.log(a);
+ }
+ expect_stdout: "PASS"
+}