Uploaded image for project: 'Groovy'
  1. Groovy
  2. GROOVY-3082

ASTNode column data

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 1.5.6
    • Fix Version/s: 1.5.7
    • Component/s: parser
    • Labels:
      None

      Description

      It would be great to have documentation for org.codehaus.groovy.ast.ASTNode:

      getLineNumber()
      getColumnNumber()
      getLastLineNumber()
      getLastColumnNumber()

      In certain cases there seems to be a deviation from the right value (+1). However it is hard to say whether it is correct without doc. I guess it is not.
      Small sample:

         ["one","two"].listIter
      

      For "two" it gives: columnNumber=11, lastColumnNumber=16 (should it be 15?)
      For the list expression: columnNumber=4,lastColumnNumber=17(should it be 16?)

      Initial column numbers seem to be ok.

        Attachments

          Activity

            People

            • Assignee:
              blackdrag Jochen Theodorou
              Reporter:
              phejl Petr Hejl
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: