aboutsummaryrefslogtreecommitdiff
path: root/test/compress/if_return.js
diff options
context:
space:
mode:
Diffstat (limited to 'test/compress/if_return.js')
-rw-r--r--test/compress/if_return.js22
1 files changed, 22 insertions, 0 deletions
diff --git a/test/compress/if_return.js b/test/compress/if_return.js
index 0ac45c3c..c09d67b6 100644
--- a/test/compress/if_return.js
+++ b/test/compress/if_return.js
@@ -302,3 +302,25 @@ issue_1437_conditionals: {
}
}
}
+
+issue_512: {
+ options = {
+ conditionals: true,
+ if_return: true,
+ }
+ input: {
+ function a() {
+ if (b()) {
+ c();
+ return;
+ }
+ throw e;
+ }
+ }
+ expect: {
+ function a() {
+ if (!b()) throw e;
+ c();
+ }
+ }
+}