Skip to content

Commit 3c08cf8

Browse files
committed
make UB during CTFE a hard error
1 parent 1989b9a commit 3c08cf8

File tree

1 file changed

+1
-0
lines changed
  • compiler/rustc_middle/src/mir/interpret

1 file changed

+1
-0
lines changed

compiler/rustc_middle/src/mir/interpret/error.rs

+1
Original file line numberDiff line numberDiff line change
@@ -525,6 +525,7 @@ impl InterpError<'_> {
525525
use InterpError::*;
526526
match *self {
527527
MachineStop(ref err) => err.is_hard_err(),
528+
InterpError::UndefinedBehavior(_) => true,
528529
_ => false,
529530
}
530531
}

0 commit comments

Comments
 (0)