]> git.lizzy.rs Git - rust.git/blobdiff - compiler/rustc_typeck/src/check/fn_ctxt/_impl.rs
Auto merge of #91354 - fee1-dead:const_env, r=spastorino
[rust.git] / compiler / rustc_typeck / src / check / fn_ctxt / _impl.rs
index 6dbcf3c3c6edc0a5d9fd17f7dacdd69d3ef07947..8afacf6027d80ffffbc297b5ad4e27ae1af98dcb 100644 (file)
@@ -1091,12 +1091,9 @@ pub(in super::super) fn could_remove_semicolon(
                         (_, _) => return None,
                     };
 
-                let last_hir_id = self.tcx.hir().local_def_id_to_hir_id(last_local_id);
-                let exp_hir_id = self.tcx.hir().local_def_id_to_hir_id(exp_local_id);
-
                 match (
-                    &self.tcx.hir().expect_item(last_hir_id).kind,
-                    &self.tcx.hir().expect_item(exp_hir_id).kind,
+                    &self.tcx.hir().expect_item(last_local_id).kind,
+                    &self.tcx.hir().expect_item(exp_local_id).kind,
                 ) {
                     (
                         hir::ItemKind::OpaqueTy(hir::OpaqueTy { bounds: last_bounds, .. }),