Details
-
Type:
Bug
-
Status:
Resolved
-
Priority:
Minor
-
Resolution: Fixed
-
Affects Version/s: 2.0.0RC1
-
Fix Version/s: 2.7.2.Release
-
Component/s: Formatting
-
Labels:None
-
Number of attachments :
Description
It seems that Groovy does not always follow the indentation rules setup in the Java indentation setup dialogs, although it does obey most of them,
For instance once I have told Java how I want to format wrapped argument lists I see Java code would format as follows...
(Settings Indentation: mixed, Line Wrapping/function calls/arguments, wrap only when necessary, indent on column)
fred(one, two, three, four)
However Groovy code seems to ignore that setting, and does not provide its own, so it indents as follows...
fred(one, two,
three, four)
or even worse...
fred(
one, two,
three, four)
First it seems to use only tabs to indent (ignoring the smart indent option), and it ignores the align columns.
If the groovy option is to use spaces to indent, then it does the same bad indentation just using spaces.
I think that the solution is to either follow the Java indentation rules, or create a groovy set of indentation rules.
There are a number of code formatting and indentation issues that I plan on having a look at for 2.0.1.