On Thu, 30 Oct 2025 23:13:02 GMT, Naoto Sato <[email protected]> wrote:

>> Upgrading the CLDR to version 48.0. A corresponding CSR has also been 
>> drafted.
>
> Naoto Sato has updated the pull request incrementally with one additional 
> commit since the last revision:
> 
>   .md files

make/data/cldr/common/main/tok.xml line 444:

> 442:                                  <dateFormatLength type="long">
> 443:                                          <dateFormat>
> 444:                                                  <pattern>'tenpo' 'sike' 
> #y 'la' 'tenpo' MMMM 'la' 'tenpo' 'suno' #d</pattern>

I think `DateTimeFormatter` doesn't handle the new patterns for `tok`, I am 
seeing the following crash with these changes:


jshell> 
Instant.parse("2018-07-16T23:58:59.000000200Z").atZone(ZoneId.of("UTC")).format(DateTimeFormatter.ofLocalizedDate(FormatStyle.LONG).withLocale(Locale.of("tok")))
|  Exception java.lang.IllegalArgumentException: Pattern includes reserved 
character: '#'
|        at DateTimeFormatterBuilder.parsePattern 
(DateTimeFormatterBuilder.java:2056)
|        at DateTimeFormatterBuilder.appendPattern 
(DateTimeFormatterBuilder.java:1910)
|        at DateTimeFormatterBuilder$LocalizedPrinterParser.lambda$formatter$0 
(DateTimeFormatterBuilder.java:5181)
|        at ConcurrentHashMap.computeIfAbsent (ConcurrentHashMap.java:1727)
|        at DateTimeFormatterBuilder$LocalizedPrinterParser.formatter 
(DateTimeFormatterBuilder.java:5179)
|        at DateTimeFormatterBuilder$LocalizedPrinterParser.format 
(DateTimeFormatterBuilder.java:5154)
|        at DateTimeFormatterBuilder$CompositePrinterParser.format 
(DateTimeFormatterBuilder.java:2547)
|        at DateTimeFormatter.formatTo (DateTimeFormatter.java:1907)
|        at DateTimeFormatter.format (DateTimeFormatter.java:1881)
|        at ZonedDateTime.format (ZonedDateTime.java:2158)
|        at (#6:1)

-------------

PR Review Comment: https://git.openjdk.org/jdk/pull/28076#discussion_r2483784510

Reply via email to