Skip to main content

Module patch

Module patch 

Source

Re-exportsΒ§

use rustc_data_structures::fx::FxHashMap; πŸ”’
use rustc_index::Idx; πŸ”’
use rustc_middle::ty::Ty; πŸ”’
use rustc_span::Span; πŸ”’
use tracing::debug; πŸ”’
use rustc_middle::mir::*; πŸ”’

StructsΒ§

MirPatch πŸ”’
This struct lets you β€œpatch” a MIR body, i.e. modify it. You can queue up various changes, such as the addition of new statements and basic blocks and replacement of terminators, and then apply the queued changes all at once with apply. This is useful for MIR transformation passes.