Fix the span for try shorthand expressions
This commit is contained in:
parent
c0b8c43820
commit
05e4116af2
2 changed files with 21 additions and 1 deletions
|
@ -2576,7 +2576,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);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue