Auto merge of #32711 - marcusklaas:try-shorthand-span-fix, r=nagisa
Fix the span for try shorthand expressions My five character contribution to the rust parser! Fixes https://github.com/rust-lang/rust/issues/32709.
This commit is contained in:
@@ -2578,7 +2578,7 @@ impl<'a> Parser<'a> {
|
||||
loop {
|
||||
// expr?
|
||||
while self.eat(&token::Question) {
|
||||
let hi = self.span.hi;
|
||||
let hi = self.last_span.hi;
|
||||
e = self.mk_expr(lo, hi, ExprKind::Try(e), None);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user