commit | 2e20f6a6229104dc14e04ad8e91e39afb092279c | [log] [tgz] |
---|---|---|
author | Chih-Hung Hsieh <[email protected]> | Mon Oct 07 12:26:11 2019 -0700 |
committer | android-build-merger <[email protected]> | Mon Oct 07 12:26:11 2019 -0700 |
tree | 0d63602442b8632d4e1ce192154dcb2c95a1a01b | |
parent | a94307be8d335558b16d54a7051ff3c979059924 [diff] | |
parent | 1809e3e8893e8d9fdec6b842427b7ffdbeb92a23 [diff] |
Add explicit default 2015. am: 1809e3e889 Change-Id: Idc40f05b4e68f1ca7c142a6a45e96998d51d21d9
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"