Skip to content

Commit 49b6798

Browse files
committed
Rust: crate_graph: extract only public items
1 parent 2de8165 commit 49b6798

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

rust/extractor/src/crate_graph.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -175,7 +175,7 @@ fn emit_module_items(
175175
let mut items = Vec::new();
176176
let item_scope = &module.scope;
177177
for (name, item) in item_scope.entries() {
178-
let def = item.with_visibility(ra_ap_hir::Visibility::Public);
178+
let def = item.filter_visibility(|x| matches!(x, ra_ap_hir::Visibility::Public));
179179
if let Some(ra_ap_hir_def::per_ns::Item {
180180
def: value,
181181
vis,

0 commit comments

Comments
 (0)