about summary refs log tree commit diff
path: root/src/liballoc
diff options
context:
space:
mode:
authorSebastian Dröge <sebastian@centricular.com>2018-01-02 01:46:50 +0200
committerSebastian Dröge <sebastian@centricular.com>2018-01-02 10:00:58 +0200
commit9957cf60232d05db250e6c3b89210850bc7b1839 (patch)
treed2b02084efb4b2f49501abb6ccbd5603582275ff /src/liballoc
parentb65f0bedd2f22d9661ecb7092f07746dc2ccfb0d (diff)
downloadrust-9957cf60232d05db250e6c3b89210850bc7b1839.tar.gz
rust-9957cf60232d05db250e6c3b89210850bc7b1839.zip
Consistently use chunk_size as the field name for Chunks and ChunksMut
Previously Chunks used size and ChunksMut used chunk_size
Diffstat (limited to 'src/liballoc')
-rw-r--r--src/liballoc/slice.rs12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/liballoc/slice.rs b/src/liballoc/slice.rs
index ab574c9f7e7..b880616833a 100644
--- a/src/liballoc/slice.rs
+++ b/src/liballoc/slice.rs
@@ -606,14 +606,14 @@ impl<T> [T] {
         core_slice::SliceExt::windows(self, size)
     }
 
-    /// Returns an iterator over `size` elements of the slice at a
-    /// time. The chunks are slices and do not overlap. If `size` does
+    /// Returns an iterator over `chunk_size` elements of the slice at a
+    /// time. The chunks are slices and do not overlap. If `chunk_size` does
     /// not divide the length of the slice, then the last chunk will
-    /// not have length `size`.
+    /// not have length `chunk_size`.
     ///
     /// # Panics
     ///
-    /// Panics if `size` is 0.
+    /// Panics if `chunk_size` is 0.
     ///
     /// # Examples
     ///
@@ -627,8 +627,8 @@ impl<T> [T] {
     /// ```
     #[stable(feature = "rust1", since = "1.0.0")]
     #[inline]
-    pub fn chunks(&self, size: usize) -> Chunks<T> {
-        core_slice::SliceExt::chunks(self, size)
+    pub fn chunks(&self, chunk_size: usize) -> Chunks<T> {
+        core_slice::SliceExt::chunks(self, chunk_size)
     }
 
     /// Returns an iterator over `chunk_size` elements of the slice at a time.