From 3d85f73def1869b971399bfcef7fa71cf2d83163 Mon Sep 17 00:00:00 2001 From: "Stephen E. Baker" <baker.stephen.e@gmail.com> Date: Tue, 17 Jan 2017 14:39:16 -0500 Subject: [PATCH] Clarify when range is removed by drain Based on a discussion on #rust-beginners the existing note for drain is confusing. This new wording was suggested. --- src/libcollections/vec.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/libcollections/vec.rs b/src/libcollections/vec.rs index 4b05f8062e8bc..c5b904c8a2f0e 100644 --- a/src/libcollections/vec.rs +++ b/src/libcollections/vec.rs @@ -1023,8 +1023,8 @@ impl<T> Vec<T> { /// Create a draining iterator that removes the specified range in the vector /// and yields the removed items. /// - /// Note 1: The element range is removed even if the iterator is not - /// consumed until the end. + /// Note 1: The element range is removed even if the iterator is only + /// partially consumed or not consumed at all. /// /// Note 2: It is unspecified how many elements are removed from the vector, /// if the `Drain` value is leaked.