This repository was archived by the owner on Mar 21, 2022. It is now read-only.

Description
Currently, DayPeriodFormatter only uses a locale's language code to determine the day period string. However, some rule sets have regional variations, such as es_cO, for "Spanish (Colombia)". These should be selected for matching locales.
This should be as straightforward as changing the current implementation to make two checks, first with and then without the region code. The only real trick is matching the identifier format for case and punctuation (e.g. Locale.identifier BCP 47 es-CO -> CLDR key es_co)
|
let ruleSet = DayPeriodFormatter.ruleSetsByLanguageCode[languageCode], |