auto merge of #12879 : Aatch/rust/rustdoc-mod-privacy, r=alexcrichton
Modules don't actually inherit privacy, so anything other than Public should be considered private. Fixes #12801 cc @cmr
This commit is contained in:
commit
7532d20a17
@ -128,7 +128,8 @@ impl<'a> fold::DocFolder for Stripper<'a> {
|
||||
}
|
||||
}
|
||||
|
||||
clean::ViewItemItem(..) => {
|
||||
clean::ViewItemItem(..) |
|
||||
clean::ModuleItem(..) => {
|
||||
if i.visibility != Some(ast::Public) {
|
||||
return None
|
||||
}
|
||||
@ -140,9 +141,6 @@ impl<'a> fold::DocFolder for Stripper<'a> {
|
||||
}
|
||||
}
|
||||
|
||||
// handled below
|
||||
clean::ModuleItem(..) => {}
|
||||
|
||||
// trait impls for private items should be stripped
|
||||
clean::ImplItem(clean::Impl{ for_: clean::ResolvedPath{ id: ref for_id, .. }, .. }) => {
|
||||
if !self.exported_items.contains(for_id) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user