0.5.0 Jan 31, 2022
0.4.0 Nov 2, 2021
0.3.0 Jul 29, 2021
0.2.0 Apr 29, 2021
0.1.0 Oct 15, 2020

#77 in #region


Used in icu_provider_cldr

Custom license

290KB
5K SLoC

icu_locid_macros crates.io

icu_locid_macros is one of the ICU4X components.

This API provides convenience macros for icu_locid.

Examples

use icu_locid_macros::{language, region, langid};

let lid = langid!("EN_US");

assert_eq!(lid.language, language!("en"));
assert_eq!(lid.region, Some(region!("US")));

More Information

For more information on development, authorship, contributing etc. please visit ICU4X home page.


lib.rs:

icu_locid_macros is one of the ICU4X components.

This API provides convenience macros for icu_locid.

Examples

use icu_locid_macros::{language, region, langid};

let lid = langid!("EN_US");

assert_eq!(lid.language, language!("en"));
assert_eq!(lid.region, Some(region!("US")));

Dependencies

~3MB
~58K SLoC