commit | 0159bcef0a07e9b3d87f4c3a3679b5c9b2f7c261 | [log] [tgz] |
---|---|---|
author | Chih-Hung Hsieh <chh@google.com> | Fri Mar 20 12:45:39 2020 -0700 |
committer | Chih-Hung Hsieh <chh@google.com> | Fri Mar 20 12:54:08 2020 -0700 |
tree | 19be29ddc439228c7153d0c1dba5e437723a3370 | |
parent | a665ab8f120fc5449b2772d062afb77db3bed704 [diff] |
Fill back missing NOTICE,METADATA,*LICENSE* files Bug: 150877376 Test: make Test: atest --host -c --include-subdirs external/rust/crates Change-Id: Ie36b9b6320731f576a6c0919d177c606549e8403
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.
You can use this package in your project by adding the following to your Cargo.toml
:
[dependencies] unicode-xid = "0.1.0"