Fix unsafetyck disabling for custom MIR
This commit is contained in:
parent
21ee03e062
commit
c1b27eea45
4 changed files with 30 additions and 1 deletions
|
@ -500,7 +500,7 @@ fn unsafety_check_result<'tcx>(
|
|||
// `mir_built` force this.
|
||||
let body = &tcx.mir_built(def).borrow();
|
||||
|
||||
if body.should_skip() {
|
||||
if body.is_custom_mir() {
|
||||
return tcx.arena.alloc(UnsafetyCheckResult {
|
||||
violations: Vec::new(),
|
||||
used_unsafe_blocks: FxHashSet::default(),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue