-
Notifications
You must be signed in to change notification settings - Fork 13.3k
Prevent specialized ZipImpl from calling __iterator_get_unchecked
twice with the same index
#82292
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
Conversation
r? @m-ou-se (rust-highfive has picked a reviewer for you, use r? to override) |
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.
Looks good to me. Can you resolve the merge conflict?
bdf0a3c
to
2432f75
Compare
@rustbot label -S-waiting-on-author +S-waiting-on-review |
☔ The latest upstream changes (presumably #82795) made this pull request unmergeable. Please resolve the merge conflicts. |
…e with the same index after calling next_back
2432f75
to
c1bfb9a
Compare
Merge conflict solved, this should be ready for review/merge now. TIL there's an S-blocked label. @rustbot label -S-blocked +S-waiting-on-review |
Thanks! @bors r+ |
📌 Commit c1bfb9a has been approved by |
Prevent specialized ZipImpl from calling `__iterator_get_unchecked` twice with the same index Fixes rust-lang#82291 It's open for review, but conflicts with rust-lang#82289, wait before merging. The conflict involves only the new test, so it should be rather trivial to fix.
Prevent specialized ZipImpl from calling `__iterator_get_unchecked` twice with the same index Fixes rust-lang#82291 It's open for review, but conflicts with rust-lang#82289, wait before merging. The conflict involves only the new test, so it should be rather trivial to fix.
Prevent specialized ZipImpl from calling `__iterator_get_unchecked` twice with the same index Fixes rust-lang#82291 It's open for review, but conflicts with rust-lang#82289, wait before merging. The conflict involves only the new test, so it should be rather trivial to fix.
Prevent specialized ZipImpl from calling `__iterator_get_unchecked` twice with the same index Fixes rust-lang#82291 It's open for review, but conflicts with rust-lang#82289, wait before merging. The conflict involves only the new test, so it should be rather trivial to fix.
Rollup of 13 pull requests Successful merges: - rust-lang#77916 (Change built-in kernel targets to be os = none throughout) - rust-lang#82130 (Make some Option, Result methods unstably const) - rust-lang#82292 (Prevent specialized ZipImpl from calling `__iterator_get_unchecked` twice with the same index) - rust-lang#82402 (Remove RefCell around `module_trait_cache`) - rust-lang#82592 (Improve transmute docs with further clarifications) - rust-lang#82651 (Cleanup rustdoc warnings) - rust-lang#82720 (Fix diagnostic suggests adding type `[type error]`) - rust-lang#82751 (improve offset_from docs) - rust-lang#82793 (Move some tests to more suitable subdirs) - rust-lang#82803 (rustdoc: Add an unstable option to print all unversioned files) - rust-lang#82808 (Sync rustc_codegen_cranelift) - rust-lang#82822 (Fix typo) - rust-lang#82837 (tweak MaybeUninit docs) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
Some history: The Zip TrustedRandomAccess specialization has tried to emulate the side-effects of the naive implementation for a long time, including backwards iteration. rust-lang#82292 tried to fix unsoundness (rust-lang#82291) in that side-effect-preservation code, but this introduced some panic-safety unsoundness (rust-lang#86443), but the fix rust-lang#86452 didn't fix it for nested Zip iterators (rust-lang#137255). Rather than piling yet another fix ontop of this heap of fixes this PR reduces the number of cases in which side-effects will be preserved; the necessary API guarantee change was approved in rust-lang#83791 but we haven't made use of that so far.
Some history: The Zip TrustedRandomAccess specialization has tried to emulate the side-effects of the naive implementation for a long time, including backwards iteration. rust-lang#82292 tried to fix unsoundness (rust-lang#82291) in that side-effect-preservation code, but this introduced some panic-safety unsoundness (rust-lang#86443), but the fix rust-lang#86452 didn't fix it for nested Zip iterators (rust-lang#137255). Rather than piling yet another fix ontop of this heap of fixes this PR reduces the number of cases in which side-effects will be preserved; the necessary API guarantee change was approved in rust-lang#83791 but we haven't made use of that so far.
Fixes #82291
It's open for review, but conflicts with #82289, wait before merging. The conflict involves only the new test, so it should be rather trivial to fix.