commit | e8afd53217f318f7ba0ef69319e593edeef8c55d | [log] [tgz] |
---|---|---|
author | Yimin Li <[email protected]> | Fri Oct 21 20:58:09 2022 -0700 |
committer | Yimin Li <[email protected]> | Fri Oct 21 20:58:09 2022 -0700 |
tree | 2f638b0af631bc4d9825f4ea5d5afa19e188b68a | |
parent | 83ff69963b4967494d576a20eec46fa8e1c0cd00 [diff] | |
parent | 070bfea6778ffb2022e3601532deeff09de03318 [diff] |
Merge commit '070bfea6778ffb2022e3601532deeff09de03318' of sso://googleplex-android/platform/external/rust/crates/unicode-xid into HEAD Change-Id: Icf48ac4a97dbaddc30f8ad1de407da8323cdde6e
Determine if a char
is a valid identifier for a parser and/or lexer according to Unicode Standard Annex #31 rules.
extern crate unicode_xid; use unicode_xid::UnicodeXID; fn main() { let ch = 'a'; println!("Is {} a valid start of an identifier? {}", ch, UnicodeXID::is_xid_start(ch)); }
unicode-xid supports a no_std
feature. This eliminates dependence on std, and instead uses equivalent functions from core.