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

Case folding bug: 13F8 does not become 13F0 on JDK 9

XMLWordPrintable

      FULL PRODUCT VERSION :
      java version "9"
      Java(TM) SE Runtime Environment (build 9+181)
      Java HotSpot(TM) 64-Bit Server VM (build 9+181, mixed mode)

      ADDITIONAL OS VERSION INFORMATION :
      Microsoft Windows [Version 6.3.9600]

      A DESCRIPTION OF THE PROBLEM :
      According to CaseFolding-8.0.0.txt the code point 13F8 must become 13F0 by String.toUpperCase().toLowerCase(). Unfortunately it does not on JRE 9.

      STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
      jshell> new String(new byte[] {0x13, (byte) 0xF8}).toUpperCase().toLowerCase().codePoints().mapToObj(Integer::toHexString).collect(Collectors.joining())

      EXPECTED VERSUS ACTUAL BEHAVIOR :
      EXPECTED -
      "13f0" according to CaseFolding-8.0.0.txt which says "13F8; C; 13F0; # CHEROKEE SMALL LETTER YE" for this particular case
      ACTUAL -
      "13f8"

      ERROR MESSAGES/STACK TRACES THAT OCCUR :
      There is neither an error message not a crash log.

      REPRODUCIBILITY :
      This bug can be reproduced always.

      ---------- BEGIN SOURCE ----------
      jshell> new String(new byte[] {0x13, (byte) 0xF8}).toUpperCase().toLowerCase().codePoints().mapToObj(Integer::toHexString).collect(Collectors.joining())
      ---------- END SOURCE ----------

      CUSTOMER SUBMITTED WORKAROUND :
      There is no existing workaround.

            rgoel Rachna Goel (Inactive)
            webbuggrp Webbug Group
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: