Skip to content

Commit 3101de2

Browse files
committed
Do not use DUMMY_SP in lowering.
1 parent ffbbfe4 commit 3101de2

File tree

1 file changed

+2
-2
lines changed
  • compiler/rustc_ast_lowering/src

1 file changed

+2
-2
lines changed

compiler/rustc_ast_lowering/src/expr.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ use rustc_middle::span_bug;
1313
use rustc_middle::ty::TyCtxt;
1414
use rustc_session::errors::report_lit_error;
1515
use rustc_span::source_map::{Spanned, respan};
16-
use rustc_span::{DUMMY_SP, DesugaringKind, Ident, Span, Symbol, sym};
16+
use rustc_span::{DesugaringKind, Ident, Span, Symbol, sym};
1717
use thin_vec::{ThinVec, thin_vec};
1818
use visit::{Visitor, walk_expr};
1919

@@ -508,7 +508,7 @@ impl<'hir> LoweringContext<'_, 'hir> {
508508
let last_segment = path.segments.last_mut().unwrap();
509509
assert!(last_segment.args.is_none());
510510
last_segment.args = Some(AstP(GenericArgs::AngleBracketed(AngleBracketedArgs {
511-
span: DUMMY_SP,
511+
span: last_segment.span().shrink_to_hi(),
512512
args: generic_args,
513513
})));
514514

0 commit comments

Comments
 (0)