Lines Matching full:let
53 /// let s: &str = "a";
54 /// let ss: String = s.to_owned();
56 /// let v: &[i32] = &[1, 2];
57 /// let vv: Vec<i32> = v.to_owned();
73 /// let mut s: String = String::new();
76 /// let mut v: Vec<i32> = Vec::new();
124 /// let v = input[i];
133 /// let slice = [0, 1, 2];
134 /// let mut input = Cow::from(&slice[..]);
138 /// let slice = [-1, 0, 1];
139 /// let mut input = Cow::from(&slice[..]);
143 /// let mut input = Cow::from(vec![-1, 0, 1]);
163 /// let readonly = [1, 2];
164 /// let borrowed = Items::new((&readonly[..]).into());
170 /// let mut clone_on_write = borrowed;
175 /// // The data was mutated. Let's check it out.
202 let b: &B = o.borrow(); in clone()
225 /// let cow = Cow::Borrowed("moo");
228 /// let bull: Cow<'_, str> = Cow::Owned("...moo?".to_string());
248 /// let cow: Cow<'_, str> = Cow::Owned("moo".to_string());
251 /// let bull = Cow::Borrowed("...moo?");
269 /// let mut cow = Cow::Borrowed("foo");
302 /// let s = "Hello world!";
303 /// let cow = Cow::Borrowed(s);
317 /// let s = "Hello world!";
318 /// let cow: Cow<str> = Cow::Owned(String::from(s));
473 if let Cow::Borrowed(lhs) = *self { in add_assign()
474 let mut s = String::with_capacity(lhs.len() + rhs.len()); in add_assign()
490 if let Cow::Borrowed(lhs) = *self { in add_assign()
491 let mut s = String::with_capacity(lhs.len() + rhs.len()); in add_assign()