Skip to content
/ rust Public
forked from rust-lang/rust

Commit de6caff

Browse files
authored
Rollup merge of rust-lang#114223 - ryanoneill:vec-indexing-doc-language, r=workingjubilee
Documentation: Fix Stilted Language in Vec->Indexing Problem Language in the Vec->Indexing documentation sounds stilted due to incorrect word ordering: "... type allows to access values by index." Solution Reorder words in the Vec->Indexing documentation to flow better: "... type allows access to values by index." The phrase "allows access to" also matches other existing documentation.
2 parents a964f94 + 9a01a23 commit de6caff

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

library/alloc/src/vec/mod.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -213,7 +213,7 @@ mod spec_extend;
213213
///
214214
/// # Indexing
215215
///
216-
/// The `Vec` type allows to access values by index, because it implements the
216+
/// The `Vec` type allows access to values by index, because it implements the
217217
/// [`Index`] trait. An example will be more explicit:
218218
///
219219
/// ```

0 commit comments

Comments
 (0)