icu_properties::sets

Function 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