Auto merge of #79275 - integer32llc:doc-style, r=jonas-schievink
More consistently use spaces after commas in lists in docs
This PR changes instances of lists that didn't use spaces after commas, like `vec![1,2,3]`, to `vec![1, 2, 3]` to be more consistent with idiomatic Rust style (the way these were looks strange to me, especially because there are often lists that *do* use spaces after the commas later in the same code block 😬).
I noticed one of these in an example in the stdlib docs and went looking for more, but as far as I can see, I'm only changing those spots in user-facing documentation or rustc output, and the changes make no semantic difference.
This commit is contained in:
commit
20328b5323
8 changed files with 18 additions and 18 deletions
|
@ -1041,7 +1041,7 @@ impl<T, A: AllocRef> Vec<T, A> {
|
|||
/// }
|
||||
/// x.set_len(size);
|
||||
/// }
|
||||
/// assert_eq!(&*x, &[0,1,2,3]);
|
||||
/// assert_eq!(&*x, &[0, 1, 2, 3]);
|
||||
/// ```
|
||||
#[stable(feature = "vec_as_ptr", since = "1.37.0")]
|
||||
#[inline]
|
||||
|
@ -1594,7 +1594,7 @@ impl<T, A: AllocRef> Vec<T, A> {
|
|||
/// # Examples
|
||||
///
|
||||
/// ```
|
||||
/// let mut vec = vec![1,2,3];
|
||||
/// let mut vec = vec![1, 2, 3];
|
||||
/// let vec2 = vec.split_off(1);
|
||||
/// assert_eq!(vec, [1]);
|
||||
/// assert_eq!(vec2, [2, 3]);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue