File tree Expand file tree Collapse file tree 1 file changed +1
-2
lines changed
compiler/rustc_parse/src/parser Expand file tree Collapse file tree 1 file changed +1
-2
lines changed Original file line number Diff line number Diff line change @@ -1353,11 +1353,11 @@ impl<'a> Parser<'a> {
1353
1353
self . check_trailing_angle_brackets ( & seg, & [ & token:: OpenDelim ( Delimiter :: Parenthesis ) ] ) ;
1354
1354
self . check_turbofish_missing_angle_brackets ( & mut seg) ;
1355
1355
1356
+ let span = lo. to ( self . prev_token . span ) ;
1356
1357
if self . check ( & token:: OpenDelim ( Delimiter :: Parenthesis ) ) {
1357
1358
// Method call `expr.f()`
1358
1359
let args = self . parse_expr_paren_seq ( ) ?;
1359
1360
let fn_span = fn_span_lo. to ( self . prev_token . span ) ;
1360
- let span = lo. to ( self . prev_token . span ) ;
1361
1361
Ok ( self . mk_expr (
1362
1362
span,
1363
1363
ExprKind :: MethodCall ( Box :: new ( ast:: MethodCall {
@@ -1373,7 +1373,6 @@ impl<'a> Parser<'a> {
1373
1373
self . dcx ( ) . emit_err ( errors:: FieldExpressionWithGeneric ( args. span ( ) ) ) ;
1374
1374
}
1375
1375
1376
- let span = lo. to ( self . prev_token . span ) ;
1377
1376
Ok ( self . mk_expr ( span, ExprKind :: Field ( self_arg, seg. ident ) ) )
1378
1377
}
1379
1378
}
You can’t perform that action at this time.
0 commit comments