diff --git a/src/libcollections/vec.rs b/src/libcollections/vec.rs index e7b700119f90..49f6fa53b018 100644 --- a/src/libcollections/vec.rs +++ b/src/libcollections/vec.rs @@ -1213,7 +1213,7 @@ impl Vec { // Duplicate, advance r. End of vec. Truncate to w. let ln = self.len(); - if ln < 1 { return; } + if ln <= 1 { return; } // Avoid bounds checks by using raw pointers. let p = self.as_mut_ptr();