-
Notifications
You must be signed in to change notification settings - Fork 24
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
Implement iterator for all assigned Unicode Blocks #227
Conversation
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.
Awesome, @eyeplum! Could you please rebase so we can see if there are any issues needing attention?
Thanks @behnam , I will rebase and update the PR! |
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.
Awesome! Mostly looks good, one important question inline, though...
unic/ucd/block/src/block.rs
Outdated
|
||
fn new(raw_block: Option<(CharRange, &'static str)>) -> Option<Block> { | ||
match raw_block { | ||
None => None, |
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.
Hum... why do we need to be able to call new()
with None
and receive None
. It's kind of counter-intuitive to Rust's new()
pattern.
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.
Good point, I think I was trying optimize for the two use cases in this file which both provide an Option<(CharRange, &'static str)>
and expect an Option<Block>
.
Should be fixed now.
I have also added some comments about the missing surrogate code point blocks.
Awesome! Looks great! bors: r+ |
Oh, we need to fix |
Build failed |
Sure, I'm keen to help. Will send pull request shortly. |
Hey @behnam, I tried to fix those warnings for |
Copying from the other PR (#233):
|
Exactly, those build errors were actually warnings to warn us about that new compilers will drop support for top level
The And yes, now this pull request is good to merge (it passed all Travis CI and AppVeyor checks). |
bors: r+ |
This pull request partially implements #206 by implementing a block iterator for all assigned Unicode Blocks.