diff --git a/icu4c/source/data/misc/units.txt b/icu4c/source/data/misc/units.txt new file mode 100644 index 00000000000..d029e9005c8 --- /dev/null +++ b/icu4c/source/data/misc/units.txt @@ -0,0 +1,54 @@ +// TODO(CLDR-13488): This is a sample of the unitConstants and convertUnits +// entries we intend to produce. Once all the plumbing is done, data is expected +// to come from CDLR's common/supplemental/units.xml. +// +// The expected source XML for each of these lines is presented in comments. + +supplementalData:table(nofallback){ + unitConstants{ + // + f2m{"0.3048"} + // + lb2kg{"0.45359237"} + // + gravity{"9.80665"} + // + PI{"3.1415926535897932384626433832795"} + // + cup2m3{"231*f2m*f2m*f2m/16*12*12*12"} + } + convertUnits{ + // + 1{ + one:table{ + factor{"1"} + } + } + // + // + celsius{ + fahrenheit:table{ + factor{"5/9"} + offset{"-160/9"} + } + kelvin:table{ + factor{"1"} + offset{"273.15"} + } + } + // + // + // + square-meter{ + hectare:table{ + factor{"10000"} + } + acre:table{ + factor{"f2m^2 * 43560"} + } + dunam:table{ + factor{"1000"} + } + } + } +} diff --git a/tools/cldr/cldr-to-icu/src/main/java/org/unicode/icu/tool/cldrtoicu/LdmlConverter.java b/tools/cldr/cldr-to-icu/src/main/java/org/unicode/icu/tool/cldrtoicu/LdmlConverter.java index 50c79cc117d..a0b92a2b902 100644 --- a/tools/cldr/cldr-to-icu/src/main/java/org/unicode/icu/tool/cldrtoicu/LdmlConverter.java +++ b/tools/cldr/cldr-to-icu/src/main/java/org/unicode/icu/tool/cldrtoicu/LdmlConverter.java @@ -269,7 +269,7 @@ public final class LdmlConverter { .collect(toImmutableList()); if (splitDirs.isEmpty()) { - return; + return; } Map graphMetadata = new HashMap<>();