Move scrutinee HirId
into MatchSource::TryDesugar
This commit is contained in:
parent
55f8c66a60
commit
5021dde1a0
29 changed files with 41 additions and 49 deletions
|
@ -65,7 +65,7 @@ impl<'tcx, 'body> ParseCtxt<'tcx, 'body> {
|
|||
let target = self.parse_block(args[1])?;
|
||||
self.parse_call(args[2], destination, target)
|
||||
},
|
||||
ExprKind::Match { scrutinee, arms } => {
|
||||
ExprKind::Match { scrutinee, arms, .. } => {
|
||||
let discr = self.parse_operand(*scrutinee)?;
|
||||
self.parse_match(arms, expr.span).map(|t| TerminatorKind::SwitchInt { discr, targets: t })
|
||||
},
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue