1
Fork 0

Rollup merge of #109307 - cjgillot:inline-location, r=compiler-errors

Ignore `Inlined` spans when computing caller location.

Fixes https://github.com/rust-lang/rust/issues/105538
This commit is contained in:
Matthias Krüger 2023-03-20 09:46:54 +01:00 committed by GitHub
commit 3efecba6e7
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 37 additions and 5 deletions

View file

@ -880,7 +880,7 @@ impl Span {
pub fn fresh_expansion(self, expn_id: LocalExpnId) -> Span {
HygieneData::with(|data| {
self.with_ctxt(data.apply_mark(
SyntaxContext::root(),
self.ctxt(),
expn_id.to_expn_id(),
Transparency::Transparent,
))