Skip to content
This repository was archived by the owner on May 28, 2025. It is now read-only.

Commit 1480b1c

Browse files
committed
Correct comment.
1 parent d0cc00f commit 1480b1c

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

compiler/rustc_middle/src/mir/syntax.rs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -672,8 +672,10 @@ pub enum TerminatorKind<'tcx> {
672672
/// necessarily executed even in the case of a panic, for example in `-C panic=abort`. If the
673673
/// assertion does not fail, execution continues at the specified basic block.
674674
///
675-
/// When overflow checking is disabled and we are generating run-time code, the `Overflow*`
676-
/// variants of this terminator are codegened as simple `goto target`.
675+
/// When overflow checking is disabled and this is run-time MIR (as opposed to compile-time MIR
676+
/// that is used for CTFE), the following variants of this terminator behave as `goto target`:
677+
/// - `OverflowNeg(..)`,
678+
/// - `Overflow(op, ..)` if op is a checkable operation (add, sub, mul, shl, shr).
677679
Assert {
678680
cond: Operand<'tcx>,
679681
expected: bool,

0 commit comments

Comments
 (0)