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

RegExp undefined behavior for print(/a(b*)?c/.exec("ac")[1])

    XMLWordPrintable

Details

    • Bug
    • Status: Resolved
    • P4
    • Resolution: Fixed
    • 8
    • 8
    • core-libs
    • None

    Description

      print(/a(b*)?c/.exec("ac")[1])

      should print

      "undefined"

      and not

      ""

      Attachments

        Activity

          People

            hannesw Hannes Wallnoefer
            lagergren Marcus Lagergren
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: