aboutsummaryrefslogtreecommitdiff
path: root/tools/test-js-optimizer-si.js
diff options
context:
space:
mode:
authorAlon Zakai <alonzakai@gmail.com>2014-03-15 15:44:14 -0700
committerAlon Zakai <alonzakai@gmail.com>2014-03-17 17:56:17 -0700
commit6c31546ced32fd968ae50da7803964c9195ebd62 (patch)
tree46ddb131a57a612e83f5d00efe847d3794725c94 /tools/test-js-optimizer-si.js
parentf6c2bcd2a3058b4b36518aa4cabec2baa7222970 (diff)
uncommaify between ifs that can potentially be simplified
Diffstat (limited to 'tools/test-js-optimizer-si.js')
-rw-r--r--tools/test-js-optimizer-si.js21
1 files changed, 18 insertions, 3 deletions
diff --git a/tools/test-js-optimizer-si.js b/tools/test-js-optimizer-si.js
index 1d214386..5f6b334f 100644
--- a/tools/test-js-optimizer-si.js
+++ b/tools/test-js-optimizer-si.js
@@ -25,7 +25,7 @@ function a() {
h();
}
if (x) {
- f();
+ return;
if (y) {
g();
}
@@ -38,7 +38,7 @@ function a() {
}
}
if (x) {
- f();
+ return;
if (y) {
if (z) {
g();
@@ -47,7 +47,7 @@ function a() {
}
if (x) {
if (y) {
- f();
+ return;
if (z) {
g();
}
@@ -69,5 +69,20 @@ function a() {
}
f();
}
+ if (x) {
+ f();
+ x = x + 2 | 0;
+ if (y) {
+ g();
+ }
+ }
+ if (x) {
+ f();
+ x = x + 2 | 0;
+ return;
+ if (y) {
+ g();
+ }
+ }
}