Skip to content

Commit 940ceb1

Browse files
Mentioned IntoIterator earlier in keyword 'for' docs
1 parent d7f9451 commit 940ceb1

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/libstd/keyword_docs.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -473,8 +473,8 @@ mod fn_keyword {}
473473
/// * `for` is also used for [higher-ranked trait bounds] as in `for<'a> &'a T: PartialEq<i32>`.
474474
///
475475
/// for-in-loops, or to be more precise, iterator loops, are a simple syntactic sugar over a common
476-
/// practice within Rust, which is to loop over an iterator until that iterator returns `None` (or
477-
/// `break` is called).
476+
/// practice within Rust, which is to loop over anything that implements `IntoIterator` until the
477+
/// temporary iterator returns `None` (or `break` is called).
478478
///
479479
/// ```rust
480480
/// for i in 0..5 {

0 commit comments

Comments
 (0)