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

java.util.regex.PrintPattern does not print a link to the next node

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: P4
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 15
    • Component/s: core-libs
    • Labels:

      Description

      The debugging util java.util.regex.PrintPattern is used to display the internal representation structure of a compiled regex pattern.

      For a node that is followed by already printed node it is supposed to print a link to that node, but fails:

      ./java java.util.regex.PrintPattern "(?:\\d?){1}"

         Pattern: (?:\d?){1}
           0: <Start>
           1: <Prolog>
           2: <Loop {1, 1}>
           3: <Group.head 0>
           4: <Ques GREEDY>
           5: <Single "ASCII.DIGIT">
                   </Ques>
           6: </Group.tail 0> < (=>%d)>
                                               ^^^ was supposed to print 2
               </Loop>
           7: <END>

        Attachments

          Activity

            People

            Assignee:
            igerasim Ivan Gerasimov
            Reporter:
            igerasim Ivan Gerasimov
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: