Prevent some items to get generic impls listed

This commit is contained in:
Guillaume Gomez 2018-07-21 22:45:51 +02:00
parent d64c2ac01a
commit 8fa6e3fa76

View File

@ -114,7 +114,8 @@ impl<'a, 'tcx, 'rcx> AutoTraitFinder<'a, 'tcx, 'rcx> {
name: Option<String>,
) -> Vec<Item>
where F: Fn(DefId) -> Def {
if self.cx
if !self.cx.access_levels.borrow().is_doc_reachable(def_id) ||
self.cx
.tcx
.get_attrs(def_id)
.lists("doc")