javac syntax tree should more closely model the source code

XMLWordPrintable

    • Type: Sub-task
    • Resolution: Unresolved
    • Priority: P4
    • tbd
    • Affects Version/s: None
    • Component/s: tools

      Currently, some desugaring is done early, in the parser (e.g. enum constants) and MemberEnter (e.g. default constructors, super calls).

      It would be better if the tree more closely modeled the source text (up until TransTypes and Lower). This will mean adding more tree nodes. The desugaring done today should effectively be done while creating the internal semantic data structures.

      A nice goal/test would be to be able to take a source file, run it through parse() and analyze(), write out the tree, and get the same sequence of tokens found in the original file (i.e. ignoring changes in whitespace and comments.)

            Assignee:
            Jan Lahoda
            Reporter:
            Jonathan Gibbons
            Votes:
            1 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated: