Skip to content

Commit

Permalink
Auto merge of rust-lang#113078 - saethlin:mention-the-function, r=Ral…
Browse files Browse the repository at this point in the history
…fJung

Mention the panic function in CheckAlignment

Per rust-lang#112599 (comment)
r? `@RalfJung`
  • Loading branch information
bors committed Jun 27, 2023
2 parents 95978b3 + cdaac87 commit f42f19b
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions compiler/rustc_mir_transform/src/check_alignment.rs
Original file line number Diff line number Diff line change
Expand Up @@ -240,9 +240,9 @@ fn insert_alignment_check<'tcx>(
required: Operand::Copy(alignment),
found: Operand::Copy(addr),
}),
// The panic symbol that this calls is #[rustc_nounwind]. We never want to insert an
// unwind into unsafe code, because unwinding could make a failing UB check turn into
// much worse UB when we start unwinding.
// This calls panic_misaligned_pointer_dereference, which is #[rustc_nounwind].
// We never want to insert an unwind into unsafe code, because unwinding could
// make a failing UB check turn into much worse UB when we start unwinding.
unwind: UnwindAction::Unreachable,
},
});
Expand Down

0 comments on commit f42f19b

Please sign in to comment.