-
Notifications
You must be signed in to change notification settings - Fork 13.3k
Fix underflow in specialized ZipImpl::size_hint #82289
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Conversation
r? @kennytm (rust-highfive has picked a reviewer for you, use r? to override) |
@kennytm is that supposed to be the same as an |
I'm not sure if this fix interacts well with
Calling |
Oh, was this already possible even before the fix? |
It's worth considering if the fix that moved the increment of Alternatively - would it be better to rewrite the whole zip specialization in terms of a "next_unchecked" method instead, and would that be more robust? |
What does that have to do with the bug this PR should fix?
A discussion about that started here, then we moved on zulip (here). Anyway I thought you already ruled out a |
Hm, oh I thought this issue was directly caused by that, but on new reading you're right, it's not related, sorry about that. Anything from 2016 could of course be reevaluated 🙂 |
@SkiFire13 Can you resolve the merge conflict? |
30928dc
to
aeb4ea7
Compare
@rustbot label -S-waiting-on-author +S-waiting-on-review |
@bors r+ |
📌 Commit aeb4ea7 has been approved by |
Fix underflow in specialized ZipImpl::size_hint Fixes rust-lang#82282
Rollup of 10 pull requests Successful merges: - rust-lang#80723 (Implement NOOP_METHOD_CALL lint) - rust-lang#80763 (resolve: Reduce scope of `pub_use_of_private_extern_crate` deprecation lint) - rust-lang#81136 (Improved IO Bytes Size Hint) - rust-lang#81939 (Add suggestion `.collect()` for iterators in iterators) - rust-lang#82289 (Fix underflow in specialized ZipImpl::size_hint) - rust-lang#82728 (Avoid unnecessary Vec construction in BufReader) - rust-lang#82764 (Add {BTreeMap,HashMap}::try_insert) - rust-lang#82770 (Add assert_matches macro.) - rust-lang#82773 (Add diagnostic item to `Default` trait) - rust-lang#82787 (Remove unused code from main.js) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
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.
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.
Fixes #82282