From 71484121001b69aefdc41fd7192b7095250517a7 Mon Sep 17 00:00:00 2001 From: Ivan Tham Date: Sat, 29 Aug 2020 18:57:49 +0800 Subject: [PATCH] Vec slice example fix style and show type elision --- library/alloc/src/vec.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/library/alloc/src/vec.rs b/library/alloc/src/vec.rs index b4ad238680f..d39b6b701e6 100644 --- a/library/alloc/src/vec.rs +++ b/library/alloc/src/vec.rs @@ -171,7 +171,7 @@ use crate::raw_vec::RawVec; /// /// // ... and that's all! /// // you can also do it like this: -/// let x : &[usize] = &v; +/// let u: &[usize] = &v; // or &[_] /// ``` /// /// In Rust, it's more common to pass slices as arguments rather than vectors