File tree Expand file tree Collapse file tree 1 file changed +1
-1
lines changed
compiler/rustc_parse/src/parser Expand file tree Collapse file tree 1 file changed +1
-1
lines changed Original file line number Diff line number Diff line change @@ -1000,7 +1000,6 @@ impl<'a> Parser<'a> {
1000
1000
1001
1001
/// Advance the parser by one token.
1002
1002
pub fn bump ( & mut self ) {
1003
- let fallback_span = self . token . span ;
1004
1003
let ( mut next, spacing) = self . token_cursor . inlined_next ( self . desugar_doc_comments ) ;
1005
1004
self . token_cursor . num_next_calls += 1 ;
1006
1005
// We've retrieved an token from the underlying
@@ -1009,6 +1008,7 @@ impl<'a> Parser<'a> {
1009
1008
self . token_cursor . break_last_token = false ;
1010
1009
if next. span . is_dummy ( ) {
1011
1010
// Tweak the location for better diagnostics, but keep syntactic context intact.
1011
+ let fallback_span = self . token . span ;
1012
1012
next. span = fallback_span. with_ctxt ( next. span . ctxt ( ) ) ;
1013
1013
}
1014
1014
debug_assert ! ( !matches!(
You can’t perform that action at this time.
0 commit comments