Skip to content

Commit a3fdfdd

Browse files
authored
Rollup merge of rust-lang#60080 - nathankleyn:fix-issue-60068, r=Centril
Fix small errors in docs for `rchunks_exact` and `rchunks_exact_mut`. The documentation for `rchunks_exact` said it started at the beginning of the slice, bit it actually starts at the end of the slice. In addition, there were a couple of "of the slice of the slice" duplicate phrases going on for `rchunks_exact` and `rchunks_exact_mut`. This fixes rust-lang#60068.
2 parents 73307ed + d98afc5 commit a3fdfdd

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

Diff for: src/libcore/slice/mod.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -838,7 +838,7 @@ impl<T> [T] {
838838
}
839839

840840
/// Returns an iterator over `chunk_size` elements of the slice at a time, starting at the
841-
/// beginning of the slice.
841+
/// end of the slice.
842842
///
843843
/// The chunks are slices and do not overlap. If `chunk_size` does not divide the length of the
844844
/// slice, then the last up to `chunk_size-1` elements will be omitted and can be retrieved
@@ -849,7 +849,7 @@ impl<T> [T] {
849849
///
850850
/// See [`rchunks`] for a variant of this iterator that also returns the remainder as a smaller
851851
/// chunk, and [`chunks_exact`] for the same iterator but starting at the beginning of the
852-
/// slice of the slice.
852+
/// slice.
853853
///
854854
/// # Panics
855855
///
@@ -890,7 +890,7 @@ impl<T> [T] {
890890
///
891891
/// See [`rchunks_mut`] for a variant of this iterator that also returns the remainder as a
892892
/// smaller chunk, and [`chunks_exact_mut`] for the same iterator but starting at the beginning
893-
/// of the slice of the slice.
893+
/// of the slice.
894894
///
895895
/// # Panics
896896
///

0 commit comments

Comments
 (0)