Implement DoubleEndedIterator::next_chunk_back#156737
Open
asder8215 wants to merge 4 commits into
Open
Conversation
Clarify that GuardBack initializes arrays from the end. Restore performance note for iter_next_chunk_erased regarding optimization issues.
I copied the impl block from Guard without noticing that Destruct was only there for const contexts. Consumed the suggestion, thanks. Co-authored-by: Chayim Refael Friedman <chayimfr@gmail.com>
Collaborator
|
r? @tgross35 rustbot has assigned @tgross35. Use Why was this reviewer chosen?The reviewer was selected based on:
|
7cb34f0 to
210d0a1
Compare
3 tasks
This comment has been minimized.
This comment has been minimized.
210d0a1 to
41f9ab9
Compare
This comment has been minimized.
This comment has been minimized.
41f9ab9 to
0688940
Compare
This comment has been minimized.
This comment has been minimized.
…troduced next_chunk_back implementation in IntoIter, updated documentation, and added test cases for DoubleEndedIterator::next_chunk_back
0688940 to
9d29265
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR builds off on @vinDelphini's PR on introducing
DoubleEndedIterator::next_chunk_back(which will be used in a follow up PR to optimizeArrayChunks::try_rfoldonce merged). This was in the works since late Jan and I thought to pick it up and get this over the finish line as vinDelphini has been away from the PR for a couple of months. I've made sure to pull from vinDelphini's branch to keep him authored on the commits he made.Other things introduced from this PR is specialization like done for
Iterator::next_chunk, constifying some stuff, making a customDoubleEndedIterator::next_chunk_backforIntoIter(since it also has a custom impl ofIterator::next_chunk), and a bunch of tests mirroring that ofIterator::next_chunk.There's no tracking issue for this yet, but the ACP for this introduction is here. I'll create the tracking issue for this soon.
Actually, can we have
DoubleEndedIterator::next_chunk_backunderneathIterator::next_chunktracking issue?