Skip to content
/ rustc Public
forked from rust-lang/rust

Commit

Permalink
Remove a hir_to_node_id
Browse files Browse the repository at this point in the history
  • Loading branch information
Manishearth committed Jun 25, 2019
1 parent d744dcd commit 4a6914b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion clippy_lints/src/escape.rs
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ impl<'a, 'tcx> Delegate<'tcx> for EscapeDelegate<'a, 'tcx> {
fn matched_pat(&mut self, _: &Pat, _: &cmt_<'tcx>, _: MatchMode) {}
fn consume_pat(&mut self, consume_pat: &Pat, cmt: &cmt_<'tcx>, _: ConsumeMode) {
let map = &self.cx.tcx.hir();
if map.is_argument(map.hir_to_node_id(consume_pat.hir_id)) {
if map.is_argument(consume_pat.hir_id) {
// Skip closure arguments
if let Some(Node::Expr(..)) = map.find(map.get_parent_node(consume_pat.hir_id)) {
return;
Expand Down

0 comments on commit 4a6914b

Please sign in to comment.