about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--src/libcollections/vec.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libcollections/vec.rs b/src/libcollections/vec.rs
index da56b21cf0c..7a3c9bc3bb2 100644
--- a/src/libcollections/vec.rs
+++ b/src/libcollections/vec.rs
@@ -520,7 +520,7 @@ impl<T> Vec<T> {
     #[inline]
     #[stable(feature = "vec_as_slice", since = "1.7.0")]
     pub fn as_mut_slice(&mut self) -> &mut [T] {
-        &mut self[..]
+        self
     }
 
     /// Sets the length of a vector.