Skip to content

Commit b363f13

Browse files
author
Jeff
committed
Add suggested changes to the docs
1 parent 5f34c04 commit b363f13

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

library/core/src/iter/traits/collect.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,9 @@
55
/// collection of some kind.
66
///
77
/// If you want to create a collection from the contents of an iterator, the
8-
/// [`Iterator::collect()`] method is preferred. However, the compiler is
9-
/// sometimes unable to infer the full type of the collection. In these cases,
10-
/// [`FromIterator::from_iter()`] can be more concise and readable. See the
8+
/// [`Iterator::collect()`] method is preferred. However, when you need to
9+
/// specify the container type, [`FromIterator::from_iter()`] can be more
10+
/// readable than using a turbofish (e.g. `::<Vec<_>>()`). See the
1111
/// [`Iterator::collect()`] documentation for more examples of its use.
1212
///
1313
/// See also: [`IntoIterator`].

0 commit comments

Comments
 (0)