Sometimes you have to write in your source long lines, that are better to break. How do you indent the stuff ceated by this.
You can indent it the same:
very long
statement;
other statement;
That makes it harder to differentiate from the following code, as shown in the example. On the other hand you could indent it one level:
very long
statement;
other statement;
That makes it easier, but it can happen, that the long line is the start of a nested block, that you want to indent, like this:
if ((long test 1) &&
(long test 2) &&
(long test 3)) {
code executed if true;
}
In this case again it's hard to read. The third possibility I can think of, is to not break long lines at all, modern editors can handle it and create soft linebreaks. But with another editor you have to scroll sideways and you cannot influence the position, the editor breaks your long line.
What possibility do you prefer? Do you have other ideas to solve this? Can you support your preference with a good justification?