allow if {} else if {} ...
optimize unused variables and only print a warning instead