This repository has been archived by the owner on Jan 25, 2022. It is now read-only.
Add unicode escapes, allow non-ASCII identifiers & others improvements #136
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Changes:
\u{NNNNNN}
[2]. However, the bytes and byte strings don't allow unicode escapes [3], therefore, the unicode escape is placed in a different object and new objects are created for byte strings and byte characters.is
&us
(these were depreciated byisize
&usize
[4]).[a-zA-Z\x80-\xff_][a-zA-Z0-9\x80-\xff_]*
[5]). This affects Lifetimes, Macros, functions and types (to do this, I basically added\\x80-\\xFF
, and it works fine. But the POSIX character class[:ascii:]
can also be used, for example:(?:[a-zA-Z0-9_]|[^[:ascii:]])
).~
@
NOTE: The use of non-ASCII characters in identifiers is a feature of Rust, however these have some issues and aren't currently fully supported (there is even the possibility that it will be eliminated in the future) (see ref. [7]).
If you want to make some change, correction, or undo something, I have no problem.
References:
isize
andusize
: Change suffixes toisize
andusize
rust-lang/rust#22496Some Sources: