compiler: Lower fn call arg spans down to MIR

To enable improved accuracy of diagnostics in upcoming commits.
This commit is contained in:
Martin Nordholts
2024-01-12 08:21:42 +01:00
parent 924ea05103
commit 16ba56c242
47 changed files with 221 additions and 170 deletions

View File

@@ -7,6 +7,8 @@ use rustc_middle::traits::Reveal;
use rustc_middle::ty::util::IntTypeExt;
use rustc_middle::ty::GenericArgsRef;
use rustc_middle::ty::{self, Ty, TyCtxt};
use rustc_span::source_map::Spanned;
use rustc_span::DUMMY_SP;
use rustc_target::abi::{FieldIdx, VariantIdx, FIRST_VARIANT};
use std::{fmt, iter};
@@ -652,7 +654,10 @@ where
[ty.into()],
self.source_info.span,
),
args: vec![Operand::Move(Place::from(ref_place))],
args: vec![Spanned {
node: Operand::Move(Place::from(ref_place)),
span: DUMMY_SP,
}],
destination: unit_temp,
target: Some(succ),
unwind: unwind.into_action(),