"Remove needless spaces" doesn't consider spaces between parameter and method parenthesis
Hi Jörg-Michael, I found an example that isn't covered by the rule. Is it simply not covered at all, or did I overlook another rule that should have done this?
Example:
DATA(lo_example) = NEW lcl_example( iv_1 = 1
iv_2 = 1 ).
Expected:
DATA(lo_example) = NEW lcl_example( iv_1 = 1
iv_2 = 1 ).
I'm using the following options:
Hi ConjuringCoffee,
that's a good point. One possible place for this would be the "Align parameters and components" rule, but I did not want to condense the space before the closing parenthesis there, because this rule does not consider the context of multiple table rows – and someone may want to keep alignment like this:
lt_any_table = VALUE #( ( id = 1 name = 'any' )
( id = 2 name = 'other' )
( id = 3 name = 'very_long' ) ).
However, "Remove needless spaces" does consider the context above and below, so this rule could actually do this, because it could detect whether or not there are more closing parentheses in the same position that might be aligned intentionally. And in non-table-row cases, I guess there should be no reason to keep multiple spaces before the closing parenthesis anyway.
Kind regards, Jörg-Michael
Possibly related to this eventual new cleanup rule #67.