Rollup merge of #139772 - nnethercote:rm-hir-Map, r=Zalathar
Remove `hir::Map` A follow-up to https://github.com/rust-lang/rust/pull/139232. r? `@Zalathar`
This commit is contained in:
commit
9d6c95d146
8 changed files with 36 additions and 65 deletions
|
@ -6,7 +6,7 @@
|
|||
//! 1. **Shallow visit**: Get a simple callback for every item (or item-like thing) in the HIR.
|
||||
//! - Example: find all items with a `#[foo]` attribute on them.
|
||||
//! - How: Use the `hir_crate_items` or `hir_module_items` query to traverse over item-like ids
|
||||
//! (ItemId, TraitItemId, etc.) and use tcx.def_kind and `tcx.hir().item*(id)` to filter and
|
||||
//! (ItemId, TraitItemId, etc.) and use tcx.def_kind and `tcx.hir_item*(id)` to filter and
|
||||
//! access actual item-like thing, respectively.
|
||||
//! - Pro: Efficient; just walks the lists of item ids and gives users control whether to access
|
||||
//! the hir_owners themselves or not.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue