Skip to content

Commit 0c2ee48

Browse files
authored
Rollup merge of rust-lang#96038 - beyarkay:patch-1, r=m-ou-se
docs: add link from zip to unzip The docs for `Iterator::unzip` explain that it is kind of an inverse operation to `Iterator::zip` and guide the reader to the `zip` docs, but the `zip` docs don't let the user know that they can undo the `zip` operation with `unzip`. This change modifies the docs to help the user find `unzip`.
2 parents 0de7cbd + d73e328 commit 0c2ee48

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

Diff for: library/core/src/iter/traits/iterator.rs

+4
Original file line numberDiff line numberDiff line change
@@ -470,6 +470,10 @@ pub trait Iterator {
470470
/// it will first try to advance the first iterator at most one time and if it still yielded an item
471471
/// try to advance the second iterator at most one time.
472472
///
473+
/// To 'undo' the result of zipping up two iterators, see [`unzip`].
474+
///
475+
/// [`unzip`]: Iterator::unzip
476+
///
473477
/// # Examples
474478
///
475479
/// Basic usage:

0 commit comments

Comments
 (0)