]> git.lizzy.rs Git - rust.git/commitdiff
Rollup merge of #77920 - ayazhafiz:i/mut-ident-spacing, r=jyn514
authorYuki Okushi <huyuumi.dev@gmail.com>
Fri, 23 Oct 2020 09:26:24 +0000 (18:26 +0900)
committerGitHub <noreply@github.com>
Fri, 23 Oct 2020 09:26:24 +0000 (18:26 +0900)
Avoid extraneous space between visibility kw and ident for statics

Today, given a static like `static mut FOO: usize = 1`, rustdoc would
emit `static mut  FOO: usize = 1`, as it emits both the mutability kw
with a space and reserves a space after the mutability kw. This patch
fixes that misformatting.

This patch also adds some tests for emit of other statics, as I could
not find an existing test devoted to statics.

1  2 
src/librustdoc/html/render/mod.rs

Simple merge