hir: Remove opt_local_def_id_to_hir_id
and opt_hir_node_by_def_id
Also replace a few `hir_node()` calls with `hir_node_by_def_id()`
This commit is contained in:
parent
30f74ff0dc
commit
89b536dbc8
37 changed files with 135 additions and 199 deletions
|
@ -422,8 +422,7 @@ impl<'cx, 'tcx> MirBorrowckCtxt<'cx, 'tcx> {
|
|||
(None, &[][..], 0)
|
||||
};
|
||||
if let Some(def_id) = def_id
|
||||
&& let node =
|
||||
self.infcx.tcx.hir_node(self.infcx.tcx.local_def_id_to_hir_id(def_id))
|
||||
&& let node = self.infcx.tcx.hir_node_by_def_id(def_id)
|
||||
&& let Some(fn_sig) = node.fn_sig()
|
||||
&& let Some(ident) = node.ident()
|
||||
&& let Some(pos) = args.iter().position(|arg| arg.hir_id == expr.hir_id)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue