Skip to content

Commit 16cfa5c

Browse files
rustdoc: discard struct ctors from imports
1 parent 122b5b4 commit 16cfa5c

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/librustdoc/visit_ast.rs

+5
Original file line numberDiff line numberDiff line change
@@ -365,6 +365,11 @@ impl<'a, 'tcx, 'rcx> RustdocVisitor<'a, 'tcx, 'rcx> {
365365
});
366366
true
367367
}
368+
hir_map::NodeStructCtor(_) if !glob => {
369+
// struct constructors always show up alongside their struct definitions, we've
370+
// already processed that so just discard this
371+
true
372+
}
368373
_ => false,
369374
};
370375
self.view_item_stack.remove(&def_node_id);

0 commit comments

Comments
 (0)