diff options
Diffstat (limited to 'compiler/rustc_middle/src/hooks/mod.rs')
| -rw-r--r-- | compiler/rustc_middle/src/hooks/mod.rs | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/compiler/rustc_middle/src/hooks/mod.rs b/compiler/rustc_middle/src/hooks/mod.rs index b984df3646e..aa2cddad093 100644 --- a/compiler/rustc_middle/src/hooks/mod.rs +++ b/compiler/rustc_middle/src/hooks/mod.rs @@ -77,4 +77,10 @@ declare_hooks! { /// /// (Eligible functions might nevertheless be skipped for other reasons.) hook is_eligible_for_coverage(key: LocalDefId) -> bool; + + /// Create the MIR for a given `DefId` - this includes + /// unreachable code. + /// You do not want to call this yourself, instead use the cached version + /// via `mir_built` + hook build_mir(key: LocalDefId) -> mir::Body<'tcx>; } |
