Uh oh!
There was an error while loading. Please reload this page.
[WIP] Implement FusedIterator - #32999
Conversation
This trait can be used to avoid the overhead of a fuse wrapper (which is pretty high).
rust-highfive
commented
Apr 15, 2016
r? @aturon (rust_highfive has picked a reviewer for you, use r? to override) |
| #[inline] | ||
| fn next(&mut self) -> Option<<I as Iterator>::Item> { | ||
| default fn next(&mut self) -> Option<<I as Iterator>::Item> { |
There was a problem hiding this comment.
Unless I'm mistaken, that doesn't apply here (yet) because we don't have the lattice rule. That is, a specialized implementation would have to have the bound I: FusedIterator + Something and the implementation on FusedIterator isn't marked default. However, that's a good point. I'll make a note of this on the specialization issue.
hexsel
commented
Apr 16, 2016
I think the RFC link is to the wrong repo, should be rust-lang/rfcs#1581 |
Stebalien
commented
Apr 16, 2016
@hexsel github auto-linking... thanks. |
apasel422
commented
Apr 20, 2016
@Stebalien Here's another way this could be done: https://play.rust-lang.org/?gist=1c74c425ab7f916b691053348b27cb61&version=nightly&backtrace=0. |
bors
commented
Apr 22, 2016
☔ The latest upstream changes (presumably #33079) made this pull request unmergeable. Please resolve the merge conflicts. |
Stebalien
commented
Apr 28, 2016
@apasel422 that certainly gets rid of the unnecessary |
alexcrichton
commented
Jul 19, 2016
Closing due to inactivity, but feel free to reopen once the RFC is accepted! |
Pending RFC rust-lang/rfcs#1581
Only implements FusedIterator for core.
/cc @bluss, @apasel422