Auto merge of #84283 - jsha:de-emphasize-attributes, r=GuillaumeGomez
rustdoc: Reduce visual weight of attributes. Followup from #83337. As part of that PR, we stopped hiding attributes behind a toggle, because most things have just zero or one attributes. However, this made clear that the current rendering of attributes emphasizes them a lot, which distracts from function signatures. This PR changes their color of attributes to be the same as the toggles, and reduces their font weight. This also removes `#[lang]` from the list of ALLOWED_ATTRIBUTES. This attribute is an implementation detail rather than part of the public-facing documentation.  Demo at https://hoffman-andrews.com/rust/de-emph-attr/std/string/struct.String.html#method.trim
This commit is contained in:
commit
62652865b6
5 changed files with 10 additions and 4 deletions
|
@ -986,7 +986,6 @@ fn render_assoc_item(
|
|||
|
||||
const ALLOWED_ATTRIBUTES: &[Symbol] = &[
|
||||
sym::export_name,
|
||||
sym::lang,
|
||||
sym::link_section,
|
||||
sym::must_use,
|
||||
sym::no_mangle,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue