Skip to content

Commit 3175304

Browse files
authored
Rollup merge of #136466 - nnethercote:start-removing-Map, r=cjgillot
Start removing `rustc_middle::hir::map::Map` `rustc_middle::hir::map::Map` is now just a low-value wrapper around `TyCtxt`. This PR starts removing it. r? `@cjgillot`
2 parents b81c7f0 + 35c8087 commit 3175304

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

examples/rustc-driver-interacting-with-the-ast.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ impl rustc_driver::Callbacks for MyCallbacks {
7575
let item = hir_krate.item(id);
7676
// Use pattern-matching to find a specific node inside the main function.
7777
if let rustc_hir::ItemKind::Fn(_, _, body_id) = item.kind {
78-
let expr = &tcx.hir().body(body_id).value;
78+
let expr = &tcx.hir_body(body_id).value;
7979
if let rustc_hir::ExprKind::Block(block, _) = expr.kind {
8080
if let rustc_hir::StmtKind::Let(let_stmt) = block.stmts[0].kind {
8181
if let Some(expr) = let_stmt.init {

0 commit comments

Comments
 (0)