A decrement operator with a semicolon directly after it is treated as an open statement, adding an extra level of indentation to the subsequent line.
Example file:
foo--;
bar();
Re-indenting the bar line with verbose messages on gives the following messages:
GetContextIndent:1: foo--;
Increasing indent for an open statement.
I see the same behavior with a space before the decrement (foo --;), but not with a space between the decrement and the semicolon (foo-- ; or foo -- ;). The increment operator works as expected in all four cases (no extra indent level).
A decrement operator with a semicolon directly after it is treated as an open statement, adding an extra level of indentation to the subsequent line.
Example file:
Re-indenting the
bar
line with verbose messages on gives the following messages:I see the same behavior with a space before the decrement (
foo --;
), but not with a space between the decrement and the semicolon (foo-- ;
orfoo -- ;
). The increment operator works as expected in all four cases (no extra indent level).