Use min_specialization in libcore#73565
Conversation
|
r? @cramertj (rust_highfive has picked a reviewer for you, use r? to override) |
nagisa
left a comment
There was a problem hiding this comment.
Only made a very basic initial pass, got distracted before I could go through the whole PR.
src/libcore/iter/adapters/zip.rs
Outdated
There was a problem hiding this comment.
Why does this need to become pub?
There was a problem hiding this comment.
It's now used in the interface of Iterator
src/libcore/iter/adapters/zip.rs
Outdated
There was a problem hiding this comment.
Given that the default implementation simply panic!()s, this is not an unsafety invariant, is it?
|
☔ The latest upstream changes (presumably #73643) made this pull request unmergeable. Please resolve the merge conflicts. |
|
@rustbot modify labels to: +S-waiting-on-author -S-waiting-on-review |
|
Let's r? @nagisa as they left some review comments. |
src/libcore/tests/iter.rs
Outdated
There was a problem hiding this comment.
Do we actually want to enforce that the 2nd iterator consumes 1 more value than from the first iterator? I think this could go either way, but I would at least leave a comment to that effect so that a change in this behaviour wouldn’t immediately appear invalid.
|
Oh well, this will need a rebase, but r=me once that's done. Sorry for taking so long to get around to this. |
66b60da to
1a4d826
Compare
1a4d826 to
dbad8c9
Compare
|
@bors r=nagisa |
|
📌 Commit dbad8c9 has been approved by |
|
⌛ Testing commit dbad8c9 with merge 1dc99bb058f144c8f4f64b005e546c10f301901b... |
|
The job Click to expand the log.I'm a bot! I can only do what humans tell me to, so if this was not helpful or you have suggestions for improvements, please ping or otherwise contact |
|
💔 Test failed - checks-actions |
|
@bors retry |
|
⌛ Testing commit dbad8c9 with merge 2f15b6b842776d00d2eb9369deeb7dcd1b3a3baa... |
|
💔 Test failed - checks-azure |
|
@bors retry |
|
☀️ Test successful - checks-actions, checks-azure |
|
@matthewjasper I'm currently thinking how to extend |
|
|
Getting
TrustedRandomAccessto work is the main interesting thing here.get_uncheckedis now an unstable, hidden method onIteratorTrustedRandomAccessis made clearer in documentationDebugwould create aliasing references when using the specialized zip implnext_backandnth.closes #68536