A locale identifier is a structured name used to select a locale for a software service. It can encode language, writing system, region and additional preferences. The identifier names a requested configuration; it is not the full set of formatting or sorting rules.[ref]
ICU User Guide by the Unicode Consortium. Locales and Resources, The Locale Concept and Canonicalization
In the traditional International Components for Unicode syntax,
en_US identifies English with the United States region, while en_GB selects the United Kingdom region. For an original test, pass the same semantic date to a formatter twice, changing only the locale identifier. Compare the resulting text while keeping the data version and explicit format options fixed. Changing the output text does not change the stored date or its UTF-8 encoding.Parsing a locale identifier successfully does not establish that a service has data for it. A library may use fallback resources. Reproducible software tests should therefore record the requested identifier and relevant service/data versions, and inspect the effective resource choice when that matters.[ref]
ICU User Guide by the Unicode Consortium. Locales and Resources, Locales and Services; Usage: Creating Locales, constructor validity versus available resources
New to topics? Read the docs here!