Skip to content

Commit c84e692

Browse files
author
Nick Hamann
committed
Describe the Iterator enumerate() method more clearly.
1 parent 8415fa2 commit c84e692

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/libcore/iter.rs

+3-2
Original file line numberDiff line numberDiff line change
@@ -273,8 +273,9 @@ pub trait Iterator {
273273
FilterMap { iter: self, f: f }
274274
}
275275

276-
/// Creates an iterator that yields a pair of the value returned by this
277-
/// iterator plus the current index of iteration.
276+
/// Creates an iterator that yields pairs `(i, val)` where `i` is the
277+
/// current index of iteration and `val` is the value returned by the
278+
/// iterator
278279
///
279280
/// `enumerate` keeps its count as a `usize`. If you want to count by a
280281
/// different sized integer, the `zip` function provides similar

0 commit comments

Comments
 (0)