Uploaded image for project: 'Calcite'
  1. Calcite
  2. CALCITE-6502

Parser loses position information for Expression3

    XMLWordPrintableJSON

Details

    Description

      Parser.jj features the following code snipped in the Expression3 production:

              if (list1.size() == 1) {
                  // interpret as single value or query
                  return list1.get(0);
              } 
      

      This is problematic because the span of list1 is not the same as the span of its first element.
      This makes it look like the expression parsed does not include the opening and closing parens.
      This can be a problem for error reporting tools (but there are other use cases that may be impacted).

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              mbudiu Mihai Budiu
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: