about summary refs log tree commit diff
diff options
context:
space:
mode:
authorGuillaume Gomez <guillaume.gomez@huawei.com>2023-06-28 20:32:47 +0200
committerGuillaume Gomez <guillaume.gomez@huawei.com>2023-11-22 17:22:30 +0100
commit823148fa849eb9b6fb896a0ac1772a2be3bdb043 (patch)
tree620024fb0856e6143457e2fdfbf800e92e6df90d
parent0ccd5c4898c813a6cdf844a6025fa40d9433fe2d (diff)
downloadrust-823148fa849eb9b6fb896a0ac1772a2be3bdb043.tar.gz
rust-823148fa849eb9b6fb896a0ac1772a2be3bdb043.zip
Add documentation on `filter_doc_attr`
-rw-r--r--src/librustdoc/clean/mod.rs2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/librustdoc/clean/mod.rs b/src/librustdoc/clean/mod.rs
index 6619288f9cb..03b7c939d48 100644
--- a/src/librustdoc/clean/mod.rs
+++ b/src/librustdoc/clean/mod.rs
@@ -2656,6 +2656,8 @@ fn filter_doc_attr_ident(ident: Symbol, is_inline: bool) -> bool {
     }
 }
 
+/// Remove attributes from `normal` that should not be inherited by `use` re-export.
+/// Before calling this function, make sure `normal` is a `#[doc]` attribute.
 fn filter_doc_attr(normal: &mut ast::NormalAttr, is_inline: bool) {
     match normal.item.args {
         ast::AttrArgs::Delimited(ref mut args) => {