1
Fork 0

Factor out hir::Node::Binding

This commit is contained in:
Cameron Steffen 2022-06-28 13:15:30 -05:00
parent ca1e68b322
commit ec82bc1996
18 changed files with 22 additions and 37 deletions

View file

@ -997,7 +997,7 @@ impl<'a, 'tcx> Builder<'a, 'tcx> {
continue;
};
let pat = match tcx.hir().get(arg.pat.hir_id) {
Node::Pat(pat) | Node::Binding(pat) => pat,
Node::Pat(pat) => pat,
node => bug!("pattern became {:?}", node),
};
let pattern = pat_from_hir(tcx, self.param_env, self.typeck_results, pat);