commit | 2b72cb242b298840e2992218328b551a239b2ddc | [log] [tgz] |
---|---|---|
author | Chih-Hung Hsieh <chh@google.com> | Thu Oct 01 19:11:42 2020 +0000 |
committer | Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com> | Thu Oct 01 19:11:42 2020 +0000 |
tree | 158f9aed75a3b0ef2a34e968ada900d5e6bb625b | |
parent | e62dec9c4a395f4abfe53a22992ec599399dc9d3 [diff] | |
parent | 7afbb0e468f5b61859265762fe8d10d223e74a59 [diff] |
Add post_update.sh am: 7afbb0e468 Original change: https://android-review.googlesource.com/c/platform/external/rust/crates/unicode-xid/+/1443548 Change-Id: I773f50b4feb1c8515ccdc3f517a411b90afe5295
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.