GRECLIPSE
  1. GRECLIPSE
  2. GRECLIPSE-603

[formatting] indentation of wrapped argument lists is not following Java rules

    Details

    • Type: Bug Bug
    • Status: Resolved Resolved
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: 2.0.0RC1
    • Fix Version/s: 2.7.2.Release
    • Component/s: Formatting
    • Labels:
      None
    • Number of attachments :
      0

      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.

        Activity

        Hide
        Andrew Eisenberg added a comment -

        There are a number of code formatting and indentation issues that I plan on having a look at for 2.0.1.

        Show
        Andrew Eisenberg added a comment - There are a number of code formatting and indentation issues that I plan on having a look at for 2.0.1.
        Hide
        Andrew Eisenberg added a comment -

        Have not been able to look into indentation issues for 2.0.1. Will do so for 2.0.2.

        Show
        Andrew Eisenberg added a comment - Have not been able to look into indentation issues for 2.0.1. Will do so for 2.0.2.
        Hide
        Andrew Eisenberg added a comment -

        Will not get to for the 2.1.0 release.

        Show
        Andrew Eisenberg added a comment - Will not get to for the 2.1.0 release.
        Hide
        Andrew Eisenberg added a comment -

        Now working.

        Show
        Andrew Eisenberg added a comment - Now working.

          People

          • Assignee:
            Andrew Eisenberg
            Reporter:
            Jim Morris
          • Votes:
            2 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: