File tree 1 file changed +4
-5
lines changed
library/core/src/iter/traits 1 file changed +4
-5
lines changed Original file line number Diff line number Diff line change @@ -1543,11 +1543,10 @@ pub trait Iterator {
1543
1543
/// collection into another. You take a collection, call [`iter`] on it,
1544
1544
/// do a bunch of transformations, and then `collect()` at the end.
1545
1545
///
1546
- /// One of the keys to `collect()`'s power is that many things you might
1547
- /// not think of as 'collections' actually are. For example, a [`String`]
1548
- /// is a collection of [`char`]s. And a collection of
1549
- /// [`Result<T, E>`][`Result`] can be thought of as single
1550
- /// [`Result`]`<Collection<T>, E>`. See the examples below for more.
1546
+ /// `collect()` can also create instances of types that are not typical
1547
+ /// collections. For example, a [`String`] can be built from [`char`]s,
1548
+ /// and an iterator of [`Result<T, E>`][`Result`] items can be collected
1549
+ /// into `Result<Collection<T>, E>`. See the examples below for more.
1551
1550
///
1552
1551
/// Because `collect()` is so general, it can cause problems with type
1553
1552
/// inference. As such, `collect()` is one of the few times you'll see
You can’t perform that action at this time.
0 commit comments