pub struct CompilerIr {Show 13 fields
pub schema_version: String,
pub unit: UnitRef,
pub anchored_at: Option<String>,
pub symbols: Vec<ResolvedSymbol>,
pub types: Vec<ResolvedType>,
pub calls: Vec<CallSite>,
pub semantic_constructs: Vec<SemanticConstruct>,
pub expressions: Vec<ResolvedExpression>,
pub unexpanded_macros: Vec<UnexpandedMacro>,
pub cfg: Option<ControlFlowGraph>,
pub instantiations: Vec<Instantiation>,
pub effects: EffectSummary,
pub data_flow: DataFlowSummary,
}Expand description
Everything one helper found in one unit.
Fields§
§schema_version: StringThe schema this was written against.
unit: UnitRefWhat it is about.
anchored_at: Option<String>The directory the file paths in this analysis are spelled against.
A helper reports paths the way the project spells them, which is relative to the root it read the project from — not to whatever directory a scan was started in. Saying which root that was is what lets a reader turn a file it knows about into the name this analysis filed it under. Without it the two spellings can only be compared by hoping they agree, and comparing on a shared suffix instead would let one file’s answers be counted for another’s, since two files can end the same way.
None when the paths stand on their own, which is what an analysis
with no project root to speak of reports.
symbols: Vec<ResolvedSymbol>Names resolved to definitions.
types: Vec<ResolvedType>Types, referred to by index from everything else.
calls: Vec<CallSite>Calls and what they call.
semantic_constructs: Vec<SemanticConstruct>Compiler-confirmed constructs available to restricted semantic rules.
expressions: Vec<ResolvedExpression>Expression types whose anchor may cover an invocation rather than one source token.
unexpanded_macros: Vec<UnexpandedMacro>Macro invocations that were not expanded, and why.
cfg: Option<ControlFlowGraph>Control flow, when the helper offers it.
instantiations: Vec<Instantiation>Generic and template instantiations.
effects: EffectSummaryWhat the unit does. Declared, not yet computed.
data_flow: DataFlowSummaryHow values move. Declared, not yet computed.
Implementations§
Source§impl CompilerIr
impl CompilerIr
Trait Implementations§
Source§impl Clone for CompilerIr
impl Clone for CompilerIr
Source§fn clone(&self) -> CompilerIr
fn clone(&self) -> CompilerIr
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more