diff options
author | Jonas Schievink <[email protected]> | 2021-04-21 17:10:25 +0100 |
---|---|---|
committer | Jonas Schievink <[email protected]> | 2021-04-21 17:10:25 +0100 |
commit | 0414b6531996ebd6f3c8b943fac94a8784869558 (patch) | |
tree | 8cba962f60c769d7cdaf80cd29bfcbb067cb3724 /crates/hir_def/src | |
parent | e9fea823a0cc235e54b82b79dc8396294240f8d6 (diff) |
Remove `ItemTree::all_inner_items`
Diffstat (limited to 'crates/hir_def/src')
-rw-r--r-- | crates/hir_def/src/item_tree.rs | 7 |
1 files changed, 0 insertions, 7 deletions
diff --git a/crates/hir_def/src/item_tree.rs b/crates/hir_def/src/item_tree.rs index 16a94a058..eaeca01bd 100644 --- a/crates/hir_def/src/item_tree.rs +++ b/crates/hir_def/src/item_tree.rs | |||
@@ -196,13 +196,6 @@ impl ItemTree { | |||
196 | self.raw_attrs(of).clone().filter(db, krate) | 196 | self.raw_attrs(of).clone().filter(db, krate) |
197 | } | 197 | } |
198 | 198 | ||
199 | pub fn all_inner_items(&self) -> impl Iterator<Item = ModItem> + '_ { | ||
200 | match &self.data { | ||
201 | Some(data) => Some(data.inner_items.values().flatten().copied()).into_iter().flatten(), | ||
202 | None => None.into_iter().flatten(), | ||
203 | } | ||
204 | } | ||
205 | |||
206 | pub fn inner_items_of_block(&self, block: FileAstId<ast::BlockExpr>) -> &[ModItem] { | 199 | pub fn inner_items_of_block(&self, block: FileAstId<ast::BlockExpr>) -> &[ModItem] { |
207 | match &self.data { | 200 | match &self.data { |
208 | Some(data) => data.inner_items.get(&block).map(|it| &**it).unwrap_or(&[]), | 201 | Some(data) => data.inner_items.get(&block).map(|it| &**it).unwrap_or(&[]), |