optimize trivial IIFEs returning constants (#1530)

This commit is contained in:
kzc
2017-03-02 02:11:40 -05:00
committed by Alex Lam S.L
parent 9699ffb1af
commit ee3b39b909
5 changed files with 91 additions and 17 deletions

View File

@@ -1141,7 +1141,7 @@ collapse_vars_constants: {
function f3(x) {
var b = x.prop;
sideeffect1();
return b + (function() { return -9; })();
return b + -9;
}
}
}