Skip to content

Commit 7c9b3d1

Browse files
author
Jonas Schievink
committed
Remove entries_without_primitives
1 parent a80e8fe commit 7c9b3d1

File tree

2 files changed

+3
-11
lines changed

2 files changed

+3
-11
lines changed

crates/ra_hir_def/src/item_scope.rs

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -83,12 +83,6 @@ impl ItemScope {
8383
keys.into_iter().map(move |name| (name, self.get(name)))
8484
}
8585

86-
pub fn entries_without_primitives<'a>(
87-
&'a self,
88-
) -> impl Iterator<Item = (&'a Name, PerNs)> + 'a {
89-
self.entries()
90-
}
91-
9286
pub fn declarations(&self) -> impl Iterator<Item = ModuleDefId> + '_ {
9387
self.defs.iter().copied()
9488
}

crates/ra_hir_def/src/resolver.rs

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -511,11 +511,9 @@ impl Scope {
511511
});
512512
}
513513
}
514-
Scope::LocalItemsScope(body) => {
515-
body.item_scope.entries_without_primitives().for_each(|(name, def)| {
516-
f(name.clone(), ScopeDef::PerNs(def));
517-
})
518-
}
514+
Scope::LocalItemsScope(body) => body.item_scope.entries().for_each(|(name, def)| {
515+
f(name.clone(), ScopeDef::PerNs(def));
516+
}),
519517
Scope::GenericParams { params, def } => {
520518
for (local_id, param) in params.types.iter() {
521519
if let Some(name) = &param.name {

0 commit comments

Comments
 (0)