Trait rustc_mir::dataflow::DataflowResultsConsumer [−][src]
pub(crate) trait DataflowResultsConsumer<'a, 'tcx: 'a> { type FlowState: FlowsAtLocation; fn mir(&self) -> &'a Mir<'tcx>; fn visit_block_entry(
&mut self,
_bb: BasicBlock,
_flow_state: &Self::FlowState
) { ... } fn visit_statement_entry(
&mut self,
_loc: Location,
_stmt: &Statement<'tcx>,
_flow_state: &Self::FlowState
) { ... } fn visit_terminator_entry(
&mut self,
_loc: Location,
_term: &Terminator<'tcx>,
_flow_state: &Self::FlowState
) { ... } fn analyze_results(&mut self, flow_uninit: &mut Self::FlowState) { ... } fn process_basic_block(
&mut self,
bb: BasicBlock,
flow_state: &mut Self::FlowState
) { ... } }
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
DataflowResultsConsumer abstracts over walking the MIR with some already constructed dataflow results.
It abstracts over the FlowState and also completely hides the underlying flow analysis results, because it needs to handle cases where we are combining the results of multiple flow analyses (e.g. borrows + inits + uninits).
Associated Types
type FlowState: FlowsAtLocation
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
Required Methods
fn mir(&self) -> &'a Mir<'tcx>
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
Provided Methods
fn visit_block_entry(&mut self, _bb: BasicBlock, _flow_state: &Self::FlowState)
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
fn visit_statement_entry(
&mut self,
_loc: Location,
_stmt: &Statement<'tcx>,
_flow_state: &Self::FlowState
)
&mut self,
_loc: Location,
_stmt: &Statement<'tcx>,
_flow_state: &Self::FlowState
)
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
fn visit_terminator_entry(
&mut self,
_loc: Location,
_term: &Terminator<'tcx>,
_flow_state: &Self::FlowState
)
&mut self,
_loc: Location,
_term: &Terminator<'tcx>,
_flow_state: &Self::FlowState
)
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
fn analyze_results(&mut self, flow_uninit: &mut Self::FlowState)
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
fn process_basic_block(
&mut self,
bb: BasicBlock,
flow_state: &mut Self::FlowState
)
&mut self,
bb: BasicBlock,
flow_state: &mut Self::FlowState
)
🔬 This is a nightly-only experimental API. (rustc_private
)
this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml
instead?
Implementors
impl<'cx, 'gcx, 'tcx> DataflowResultsConsumer<'cx, 'tcx> for MirBorrowckCtxt<'cx, 'gcx, 'tcx> type FlowState = Flows<'cx, 'gcx, 'tcx>;