more progress on the compressor (WIP)

This commit is contained in:
Mihai Bazon
2012-09-10 15:54:17 +03:00
parent 16b12c6287
commit a41e6cfabb
4 changed files with 134 additions and 20 deletions

View File

@@ -72,3 +72,18 @@ ifs_3_should_warn: {
var jj; foo(); // 2
}
}
ifs_4: {
options = {
conditionals: true
};
input: {
if (foo && bar) {
x(foo)[10].bar.baz = something();
} else
x(foo)[10].bar.baz = something_else();
}
expect: {
x(foo)[10].bar.baz = (foo && bar) ? something() : something_else();
}
}