Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8224225

Tokenizer improvements

    XMLWordPrintable

Details

    • Enhancement
    • Resolution: Fixed
    • P3
    • 16
    • None
    • tools
    • None
    • b19

    Description

      The UnicodeReader/JavaTokenizer code is made more obscure than needed by some suboptimal implementation & naming choices:

      * UnicodeReader has both API to 'scan' a char (e.g. read next char) as well as to 'putChar' e.g. save char in a temp buffer. The buffer functionality should arguably be higher-level and moved in the JavaTokenizer itself?

      * 'putChar' has subtle overloads, some of which also advance the reader state

      * the reader 'scanChar' API could be made more intuitive by renaming it to something like 'nextChar' suggesting the underlying state change

      Attachments

        Issue Links

          Activity

            People

              jlaskey Jim Laskey
              mcimadamore Maurizio Cimadamore
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: