Function icu_properties::sets::basic_emoji

source ·
pub const fn basic_emoji() -> UnicodeSetDataBorrowed<'static>
Expand description

Characters and character sequences intended for general-purpose, independent, direct input. See Unicode Technical Standard #51 for more details.

Enabled with the compiled_data Cargo feature.

📚 Help choosing a constructor

§Example

use icu::properties::sets;

let basic_emoji = sets::basic_emoji();

assert!(!basic_emoji.contains32(0x0020));
assert!(!basic_emoji.contains_char('\n'));
assert!(basic_emoji.contains_char('🦃')); // U+1F983 TURKEY
assert!(basic_emoji.contains("\u{1F983}"));
assert!(basic_emoji.contains("\u{1F6E4}\u{FE0F}")); // railway track
assert!(!basic_emoji.contains("\u{0033}\u{FE0F}\u{20E3}"));  // Emoji_Keycap_Sequence, keycap 3