diff --git a/tests/crashes/131451.rs b/tests/crashes/131451.rs new file mode 100644 index 0000000000000..cd5b44bad8a5b --- /dev/null +++ b/tests/crashes/131451.rs @@ -0,0 +1,9 @@ +//@ known-bug: #131451 +//@ needs-rustc-debug-assertions +//@ compile-flags: -Zmir-enable-passes=+GVN -Zmir-enable-passes=+JumpThreading --crate-type=lib + +pub fn fun(terminate: bool) { + while true {} + + while !terminate {} +}