Skip to content
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

Implement Clone for iterator adaptors using functions #19837

Closed
wants to merge 1 commit into from

Conversation

bluss
Copy link
Member

@bluss bluss commented Dec 14, 2014

impl Clone wherever the underlying iterator and the predicate / mapping
function implement Clone. For example bare functions impl Clone + FnMut,
so such functions used with .map() will produce a clonable iterator.

With this change, str's .bytes() iterator becomes clonable.

Add a single test that execises .clone() on a Map.

impl Clone wherever the underlying iterator and the predicate / mapping
function implement Clone. For example bare functions impl Clone + FnMut,
so such functions used with .map() will produce a clonable iterator.

With this change, str's .bytes() iterator becomes clonable.

Add a single test that execises .clone() on a Map.
@rust-highfive
Copy link
Collaborator

Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @aturon (or someone else) soon.

If any changes to this PR are deemed necessary, please add them as extra commits. This ensures that the reviewer can see what has changed since they last reviewed the code. The way Github handles out-of-date commits, this should also make it reasonably obvious what issues have or haven't been addressed. Large or tricky changes may require several passes of review and changes.

Please see CONTRIBUTING.md for more information.

@Gankra
Copy link
Contributor

Gankra commented Dec 14, 2014

I believe this is already accomplished by #19827

@bluss
Copy link
Member Author

bluss commented Dec 14, 2014

Thank you for the pointer, I think this PR accomplishes it better.

@bluss
Copy link
Member Author

bluss commented Dec 14, 2014

Superseded by the other PR.

@bluss bluss closed this Dec 14, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants