RFR: 8303039: Utilize `coverageLevels.txt`

Steven R. Loomis duke at openjdk.org
Wed Mar 1 23:14:06 UTC 2023


On Wed, 1 Mar 2023 19:50:56 GMT, Naoto Sato <naoto at openjdk.org> wrote:

> This is a pre-requisite for supporting CLDR v43, where they combine `seeds` locales with `common` locales (https://cldr.unicode.org/index/downloads/cldr-43#h.7s25aqdv767e). In order to have the same coverage level of locales, CLDRConverter tool needs to comb through the locale files based on the `coverageLevels.txt` file, (and the ones we already included as of v42). Confirmed the same set of locales is generated before and after this modification.

Marked as reviewed by srl295 at github.com (no known OpenJDK username).

make/data/cldr/common/properties/coverageLevels.txt line 2:

> 1: #	coverageLevels.txt
> 2: #	Copyright © 2022 Unicode, Inc.

older version?

make/jdk/src/classes/build/tools/cldrconverter/CLDRConverter.java line 1212:

> 1210:                     a -> Locale.forLanguageTag(a[0].trim().replaceAll("_", "-")),
> 1211:                     a -> a[1].trim(),
> 1212:                     (v1, v2) -> v2,

this will grab all listed entries.  Right now, that will get you basic and above.  Ideally you would include if `v1` is one of `(basic|moderate|modern|comprehensive)` — I'm proposing to add `core` or maybe even `undefined` locales in this list (though no consensus yet)

make/jdk/src/classes/build/tools/cldrconverter/OtherCommonLocales.properties line 140:

> 138: 
> 139: # Not listed, but existed
> 140: sr-Latn=Serbian (Latin)

[CLDR-16449](https://unicode-org.atlassian.net/browse/CLDR-16449)

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

PR: https://git.openjdk.org/jdk/pull/12812



More information about the build-dev mailing list