rustc_mir: support MIR-inlining #[track_caller] functions.

This commit is contained in:
Eduard-Mihai Burtescu 2020-09-21 06:52:37 +03:00
parent fb36440b7a
commit 6451b39a25
8 changed files with 144 additions and 52 deletions

View file

@ -1878,6 +1878,11 @@ pub struct SourceScopeData<'tcx> {
/// `ty::Instance` is the callee, and the `Span` is the call site.
pub inlined: Option<(ty::Instance<'tcx>, Span)>,
/// Nearest (transitive) parent scope (if any) which is inlined.
/// This is an optimization over walking up `parent_scope`
/// until a scope with `inlined: Some(...)` is found.
pub inlined_parent_scope: Option<SourceScope>,
/// Crate-local information for this source scope, that can't (and
/// needn't) be tracked across crates.
pub local_data: ClearCrossCrate<SourceScopeLocalData>,