Ex_Cldr v2.3.0 Release Notes

  • ๐Ÿš€ This is the changelog for Cldr v2.3.0 released on March 4th, 2019. For older changelogs please consult the release tag on GitHub

    โœจ Enhancements

    • โž• Adds Cldr.LanguageTag.to_string/1 which converts a Cldr.LanguageTag{} into a language tag string. This is useful when creating a collator that is based upon libicu since that collator will apply the configuration specified by the u extension in the language tag. For example:
    iex> {:ok, locale} = Cldr.validate_locale "en-US-u-co-phonebk-nu-arab", MyApp.Cldr
    iex> Cldr.LanguageTag.to_string(locale)
    "en-Latn-US-u-ca-phonebk-nu-arab"
    

    ๐Ÿ› Bug Fixes

    • ๐Ÿ›  Fix a bug when parsing some locale strings which have extensions. An extension may have a list of "keyword-type" pairs or simply "keyword". Parsing was failing when only the "keyword" form was used. For example the following used to fail, but is now parsed correctly:

      iex> {:ok, locale} = Cldr.validate_locale "en-US-u-co-ca", MyApp.Cldr
      {:ok,
      %Cldr.LanguageTag{
      canonical_locale_name: "en-Latn-US",
      cldr_locale_name: "en",
      extensions: %{},
      gettext_locale_name: nil,
      language: "en",
      language_subtags: [],
      language_variant: nil,
      locale: %{calendar: "gregory", collation: "standard"},
      private_use: [],
      rbnf_locale_name: "en",
      requested_locale_name: "en-US",
      script: "Latn",
      territory: "US",
      transform: %{}
      }}
      
    • ๐Ÿ›  Fix a race condition when starting up the compile-time locale cache