From 2aa28ad4f013d520740b0e990e6bf93e0d0471b5 Mon Sep 17 00:00:00 2001 From: Arnav Jindal Date: Mon, 8 Mar 2021 11:49:26 +0530 Subject: [PATCH 1/2] Grammar Fixes --- library/core/src/array/mod.rs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/library/core/src/array/mod.rs b/library/core/src/array/mod.rs index 20251edf6f7f4..201e73c2ba614 100644 --- a/library/core/src/array/mod.rs +++ b/library/core/src/array/mod.rs @@ -42,7 +42,7 @@ pub fn from_mut(s: &mut T) -> &mut [T; 1] { /// without causing much metadata bloat. /// /// The trait is marked unsafe in order to restrict implementors to fixed-size -/// arrays. User of this trait can assume that implementors have the exact +/// arrays. A user of this trait can assume that implementors have the exact /// layout in memory of a fixed size array (for example, for unsafe /// initialization). /// @@ -382,7 +382,7 @@ impl Ord for [T; N] { // The Default impls cannot be done with const generics because `[T; 0]` doesn't // require Default to be implemented, and having different impl blocks for -// different numbers isn't supported yet. +// different numbers aren't supported yet. macro_rules! array_impl_default { {$n:expr, $t:ident $($ts:ident)*} => { @@ -489,7 +489,7 @@ impl [T; N] { /// ``` /// /// This method is particularly useful if combined with other methods, like - /// [`map`](#method.map). This way, you can can avoid moving the original + /// [`map`](#method.map). This way, you can avoid moving the original /// array if its elements are not `Copy`. /// /// ``` @@ -564,7 +564,7 @@ where /// yields fewer than `N` items, `None` is returned and all already yielded /// items are dropped. /// -/// Since the iterator is passed as mutable reference and this function calls +/// Since the iterator is passed as a mutable reference and this function calls /// `next` at most `N` times, the iterator can still be used afterwards to /// retrieve the remaining items. /// From 655155caa08af56d13bfa79753ff854634fd1417 Mon Sep 17 00:00:00 2001 From: Arnav Jindal Date: Mon, 8 Mar 2021 20:28:30 +0530 Subject: [PATCH 2/2] Update library/core/src/array/mod.rs Co-authored-by: Yuki Okushi --- library/core/src/array/mod.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/library/core/src/array/mod.rs b/library/core/src/array/mod.rs index 201e73c2ba614..8f52985d1df71 100644 --- a/library/core/src/array/mod.rs +++ b/library/core/src/array/mod.rs @@ -382,7 +382,7 @@ impl Ord for [T; N] { // The Default impls cannot be done with const generics because `[T; 0]` doesn't // require Default to be implemented, and having different impl blocks for -// different numbers aren't supported yet. +// different numbers isn't supported yet. macro_rules! array_impl_default { {$n:expr, $t:ident $($ts:ident)*} => {