diff --git a/library/alloc/src/collections/vec_deque/mod.rs b/library/alloc/src/collections/vec_deque/mod.rs index 8df7ca3411d67..fb09895239301 100644 --- a/library/alloc/src/collections/vec_deque/mod.rs +++ b/library/alloc/src/collections/vec_deque/mod.rs @@ -116,9 +116,7 @@ impl Clone for VecDeque { /// Overwrites the contents of `self` with a clone of the contents of `source`. /// /// This method is preferred over simply assigning `source.clone()` to `self`, - /// as it avoids reallocation if possible. Additionally, if the element type - /// `T` overrides `clone_from()`, this will reuse the resources of `self`'s - /// elements as well. + /// as it avoids reallocation if possible. fn clone_from(&mut self, source: &Self) { self.clear(); self.extend(source.iter().cloned()); diff --git a/library/core/src/cell.rs b/library/core/src/cell.rs index 835edc4424d8b..5f3daca500844 100644 --- a/library/core/src/cell.rs +++ b/library/core/src/cell.rs @@ -1273,7 +1273,7 @@ impl Clone for RefCell { /// # Panics /// - /// Panics if `other` is currently mutably borrowed. + /// Panics if `source` is currently mutably borrowed. #[inline] #[track_caller] fn clone_from(&mut self, source: &Self) {