Community
Participate
Working Groups
There is a single control for specifying whether a new line is inserted in control statements. This affects whether an else is on a new line and whether the while in a do-while is on a new line. I don't know if this also affects placement of catch and finally, but it would make sense if it did. The problem is that I don't want each statement type to be treated the same. I do want else, catch and finally on a new line. But I do not want the while on a new line. With the while on a new line it might be misinterpreted as an empty while loop instead of the end of the end of a do-while. With it on the same line it makes it obvious without having to go check if the block above has a do. So there should be separate options for each type of control statement.
These options have been added: FORMATTER_INSERT_NEW_LINE_BEFORE_ELSE_IN_IF_STATEMENT FORMATTER_INSERT_NEW_LINE_BEFORE_CATCH_IN_TRY_STATEMENT FORMATTER_INSERT_NEW_LINE_BEFORE_FINALLY_IN_TRY_STATEMENT FORMATTER_INSERT_NEW_LINE_BEFORE_WHILE_IN_DO_STATEMENT FORMATTER_INSERT_NEW_LINE_IN_CONTROL_STATEMENTS is deprecated. It will be removed as soon as the UI is updated to show the new options. Fixed and released in HEAD. Regression tests have been updated.
Verified for 3.0M9