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

Leading combining diacritic character in string renders incorrectly

    XMLWordPrintable

Details

    • b14
    • generic
    • windows_10

    Description

      A DESCRIPTION OF THE PROBLEM :
      A string with a leading combining diacritic (https://en.wikipedia.org/wiki/Combining_Diacritical_Marks) will render improperly in jshell

      STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
      Open a new jshell instance and create a string with a leading combining diacritic

      jshell> "\u032Ea"

      EXPECTED VERSUS ACTUAL BEHAVIOR :
      EXPECTED -
      jshell should visually separate the double-quotation mark from the string's actual contents

      $1 ==> "‌̮a"

      This can be done either by unconditionally emitting a zero-width, non-joiner (\u200C) or by detecting the presence of a leading combining diacritic in a string and conditionally emitting the zero-width, non-joiner.
      ACTUAL -
      The diacritic has combined with jshell's double-quote mark.

      $1 ==> "̮a"

      FREQUENCY : always


      Attachments

        Issue Links

          Activity

            People

              jlahoda Jan Lahoda
              webbuggrp Webbug Group
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: