-
Notifications
You must be signed in to change notification settings - Fork 13.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Put non-ascii identifiers behind a feature gate. #10605
Conversation
👍 |
|
||
// a codepoint is ascii if and only if it is one byte when | ||
// encoded as UTF-8 | ||
if s.iter().any(|c| c.len_utf8_bytes() != 1) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This could just use the is_ascii()
method defined in std::ascii
.
if s.is_ascii() {
...
}
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh, fancy.
Thanks. We'll discuss at the Tuesday meeting. |
Seems everyone's in favor so I'll just r+. |
Clippy Book Chapter Updates Reborn: Type Checking This PR adds a new chapter to the book: "Type Checking", it hasn't changed a lot from the source mainly because there wasn't many reviews on it and I haven't see a lot of things that needed a change. ## Notes - I have some doubts about the whole "`is_*` Usage" section, what do you think about it. - For discussion about the whole project, please use the tracking issue for the project rust-lang#10597 (It also contains a timeline, discussions, and more information) changelog: Add a new "Type Checking" chapter to the book r? `@flip1995`
cf. https://mail.mozilla.org/pipermail/rust-dev/2013-November/006920.html