about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--compiler/rustc_middle/src/mir/terminator.rs17
-rw-r--r--tests/mir-opt/asm_unwind_panic_abort.main.AbortUnwindingCalls.after.mir2
-rw-r--r--tests/mir-opt/basic_assignment.main.ElaborateDrops.diff6
-rw-r--r--tests/mir-opt/basic_assignment.main.SimplifyCfg-initial.after.mir6
-rw-r--r--tests/mir-opt/box_expr.main.ElaborateDrops.before.panic-abort.mir6
-rw-r--r--tests/mir-opt/box_expr.main.ElaborateDrops.before.panic-unwind.mir6
-rw-r--r--tests/mir-opt/building/enum_cast.droppy.built.after.mir2
-rw-r--r--tests/mir-opt/building/uniform_array_move_out.move_out_by_subslice.built.after.mir6
-rw-r--r--tests/mir-opt/building/uniform_array_move_out.move_out_from_end.built.after.mir6
-rw-r--r--tests/mir-opt/combine_clone_of_primitives.{impl#0}-clone.InstSimplify.panic-unwind.diff2
-rw-r--r--tests/mir-opt/derefer_inline_test.main.Derefer.panic-abort.diff2
-rw-r--r--tests/mir-opt/derefer_inline_test.main.Derefer.panic-unwind.diff2
-rw-r--r--tests/mir-opt/generator_storage_dead_unwind.main-{closure#0}.StateTransform.before.panic-unwind.mir4
-rw-r--r--tests/mir-opt/inline/asm_unwind.main.Inline.panic-abort.diff2
-rw-r--r--tests/mir-opt/inline/asm_unwind.main.Inline.panic-unwind.diff2
-rw-r--r--tests/mir-opt/inline/cycle.f.Inline.panic-unwind.diff2
-rw-r--r--tests/mir-opt/inline/cycle.g.Inline.panic-unwind.diff2
-rw-r--r--tests/mir-opt/inline/cycle.main.Inline.panic-unwind.diff2
-rw-r--r--tests/mir-opt/inline/dont_ice_on_generic_rust_call.call.Inline.panic-unwind.diff2
-rw-r--r--tests/mir-opt/inline/inline_box_fn.call.Inline.panic-unwind.diff2
-rw-r--r--tests/mir-opt/inline/inline_diverging.h.Inline.panic-unwind.diff4
-rw-r--r--tests/mir-opt/inline/inline_into_box_place.main.Inline.panic-unwind.diff2
-rw-r--r--tests/mir-opt/inline/issue_78442.bar.Inline.panic-unwind.diff2
-rw-r--r--tests/mir-opt/inline/issue_78442.bar.RevealAll.panic-unwind.diff2
-rw-r--r--tests/mir-opt/inline/unsized_argument.caller.Inline.diff2
-rw-r--r--tests/mir-opt/issue_41110.main.ElaborateDrops.panic-abort.diff8
-rw-r--r--tests/mir-opt/issue_41110.main.ElaborateDrops.panic-unwind.diff8
-rw-r--r--tests/mir-opt/issue_41110.test.ElaborateDrops.panic-abort.diff10
-rw-r--r--tests/mir-opt/issue_41110.test.ElaborateDrops.panic-unwind.diff10
-rw-r--r--tests/mir-opt/issue_41888.main.ElaborateDrops.panic-abort.diff6
-rw-r--r--tests/mir-opt/issue_41888.main.ElaborateDrops.panic-unwind.diff6
-rw-r--r--tests/mir-opt/issue_62289.test.ElaborateDrops.before.panic-abort.mir4
-rw-r--r--tests/mir-opt/issue_62289.test.ElaborateDrops.before.panic-unwind.mir4
-rw-r--r--tests/mir-opt/issue_91633.bar.built.after.mir2
-rw-r--r--tests/mir-opt/issue_91633.foo.built.after.mir2
-rw-r--r--tests/mir-opt/match_arm_scopes.complicated_match.panic-abort.SimplifyCfg-initial.after-ElaborateDrops.after.diff2
-rw-r--r--tests/mir-opt/match_arm_scopes.complicated_match.panic-unwind.SimplifyCfg-initial.after-ElaborateDrops.after.diff2
-rw-r--r--tests/mir-opt/no_spurious_drop_after_call.main.ElaborateDrops.before.panic-abort.mir2
-rw-r--r--tests/mir-opt/no_spurious_drop_after_call.main.ElaborateDrops.before.panic-unwind.mir2
-rw-r--r--tests/mir-opt/packed_struct_drop_aligned.main.SimplifyCfg-elaborate-drops.after.panic-unwind.mir2
-rw-r--r--tests/mir-opt/pre-codegen/loops.filter_mapped.PreCodegen.after.mir2
-rw-r--r--tests/mir-opt/pre-codegen/loops.mapped.PreCodegen.after.mir2
-rw-r--r--tests/mir-opt/pre-codegen/loops.vec_move.PreCodegen.after.mir2
-rw-r--r--tests/mir-opt/pre-codegen/range_iter.forward_loop.PreCodegen.after.panic-unwind.mir2
-rw-r--r--tests/mir-opt/pre-codegen/range_iter.inclusive_loop.PreCodegen.after.panic-unwind.mir2
-rw-r--r--tests/mir-opt/pre-codegen/slice_iter.enumerated_loop.PreCodegen.after.panic-unwind.mir2
-rw-r--r--tests/mir-opt/pre-codegen/slice_iter.forward_loop.PreCodegen.after.panic-unwind.mir2
-rw-r--r--tests/mir-opt/pre-codegen/slice_iter.range_loop.PreCodegen.after.panic-unwind.mir2
-rw-r--r--tests/mir-opt/pre-codegen/slice_iter.reverse_loop.PreCodegen.after.panic-unwind.mir2
-rw-r--r--tests/mir-opt/retag.main.SimplifyCfg-elaborate-drops.after.panic-unwind.mir4
-rw-r--r--tests/mir-opt/slice_drop_shim.core.ptr-drop_in_place.[String].AddMovesForPackedDrops.before.mir2
-rw-r--r--tests/mir-opt/unusual_item_types.core.ptr-drop_in_place.Vec_i32_.AddMovesForPackedDrops.before.mir2
52 files changed, 99 insertions, 90 deletions
diff --git a/compiler/rustc_middle/src/mir/terminator.rs b/compiler/rustc_middle/src/mir/terminator.rs
index c4d7f122ea9..7eddf13b3fb 100644
--- a/compiler/rustc_middle/src/mir/terminator.rs
+++ b/compiler/rustc_middle/src/mir/terminator.rs
@@ -119,6 +119,14 @@ impl UnwindTerminateReason {
         }
     }
 
+    /// A short representation of this used for MIR printing.
+    pub fn as_short_str(self) -> &'static str {
+        match self {
+            UnwindTerminateReason::Abi => "abi",
+            UnwindTerminateReason::InCleanup => "cleanup",
+        }
+    }
+
     pub fn lang_item(self) -> LangItem {
         match self {
             UnwindTerminateReason::Abi => LangItem::PanicCannotUnwind,
@@ -301,13 +309,14 @@ impl<'tcx> Debug for TerminatorKind<'tcx> {
         // `Cleanup` is already included in successors
         let show_unwind = !matches!(self.unwind(), None | Some(UnwindAction::Cleanup(_)));
         let fmt_unwind = |fmt: &mut Formatter<'_>| -> fmt::Result {
+            write!(fmt, "unwind ")?;
             match self.unwind() {
                 // Not needed or included in successors
                 None | Some(UnwindAction::Cleanup(_)) => unreachable!(),
-                Some(UnwindAction::Continue) => write!(fmt, "unwind continue"),
-                Some(UnwindAction::Unreachable) => write!(fmt, "unwind unreachable"),
+                Some(UnwindAction::Continue) => write!(fmt, "continue"),
+                Some(UnwindAction::Unreachable) => write!(fmt, "unreachable"),
                 Some(UnwindAction::Terminate(reason)) => {
-                    write!(fmt, "unwind terminate ({})", reason.as_str())
+                    write!(fmt, "terminate({})", reason.as_short_str())
                 }
             }
         };
@@ -350,7 +359,7 @@ impl<'tcx> TerminatorKind<'tcx> {
             GeneratorDrop => write!(fmt, "generator_drop"),
             UnwindResume => write!(fmt, "resume"),
             UnwindTerminate(reason) => {
-                write!(fmt, "abort(\"{}\")", reason.as_str())
+                write!(fmt, "abort({})", reason.as_short_str())
             }
             Yield { value, resume_arg, .. } => write!(fmt, "{resume_arg:?} = yield({value:?})"),
             Unreachable => write!(fmt, "unreachable"),
diff --git a/tests/mir-opt/asm_unwind_panic_abort.main.AbortUnwindingCalls.after.mir b/tests/mir-opt/asm_unwind_panic_abort.main.AbortUnwindingCalls.after.mir
index 8b9c853eb85..6c3128f8c36 100644
--- a/tests/mir-opt/asm_unwind_panic_abort.main.AbortUnwindingCalls.after.mir
+++ b/tests/mir-opt/asm_unwind_panic_abort.main.AbortUnwindingCalls.after.mir
@@ -9,7 +9,7 @@ fn main() -> () {
     bb0: {
         StorageLive(_1);
         _1 = const ();
-        asm!("", options(MAY_UNWIND)) -> [return: bb1, unwind terminate (panic in a function that cannot unwind)];
+        asm!("", options(MAY_UNWIND)) -> [return: bb1, unwind terminate(abi)];
     }
 
     bb1: {
diff --git a/tests/mir-opt/basic_assignment.main.ElaborateDrops.diff b/tests/mir-opt/basic_assignment.main.ElaborateDrops.diff
index 2b6e0fe489a..f187f959727 100644
--- a/tests/mir-opt/basic_assignment.main.ElaborateDrops.diff
+++ b/tests/mir-opt/basic_assignment.main.ElaborateDrops.diff
@@ -47,7 +47,7 @@
   
       bb2 (cleanup): {
           _5 = move _6;
--         drop(_6) -> [return: bb6, unwind terminate (panic in a destructor during cleanup)];
+-         drop(_6) -> [return: bb6, unwind terminate(cleanup)];
 +         goto -> bb6;
       }
   
@@ -71,12 +71,12 @@
       }
   
       bb6 (cleanup): {
--         drop(_5) -> [return: bb7, unwind terminate (panic in a destructor during cleanup)];
+-         drop(_5) -> [return: bb7, unwind terminate(cleanup)];
 +         goto -> bb7;
       }
   
       bb7 (cleanup): {
--         drop(_4) -> [return: bb8, unwind terminate (panic in a destructor during cleanup)];
+-         drop(_4) -> [return: bb8, unwind terminate(cleanup)];
 +         goto -> bb8;
       }
   
diff --git a/tests/mir-opt/basic_assignment.main.SimplifyCfg-initial.after.mir b/tests/mir-opt/basic_assignment.main.SimplifyCfg-initial.after.mir
index fac407ae1ea..75070ffda11 100644
--- a/tests/mir-opt/basic_assignment.main.SimplifyCfg-initial.after.mir
+++ b/tests/mir-opt/basic_assignment.main.SimplifyCfg-initial.after.mir
@@ -51,7 +51,7 @@ fn main() -> () {
 
     bb2 (cleanup): {
         _5 = move _6;
-        drop(_6) -> [return: bb6, unwind terminate (panic in a destructor during cleanup)];
+        drop(_6) -> [return: bb6, unwind terminate(cleanup)];
     }
 
     bb3: {
@@ -73,11 +73,11 @@ fn main() -> () {
     }
 
     bb6 (cleanup): {
-        drop(_5) -> [return: bb7, unwind terminate (panic in a destructor during cleanup)];
+        drop(_5) -> [return: bb7, unwind terminate(cleanup)];
     }
 
     bb7 (cleanup): {
-        drop(_4) -> [return: bb8, unwind terminate (panic in a destructor during cleanup)];
+        drop(_4) -> [return: bb8, unwind terminate(cleanup)];
     }
 
     bb8 (cleanup): {
diff --git a/tests/mir-opt/box_expr.main.ElaborateDrops.before.panic-abort.mir b/tests/mir-opt/box_expr.main.ElaborateDrops.before.panic-abort.mir
index f7cfcf27fe5..1c7ef7f8345 100644
--- a/tests/mir-opt/box_expr.main.ElaborateDrops.before.panic-abort.mir
+++ b/tests/mir-opt/box_expr.main.ElaborateDrops.before.panic-abort.mir
@@ -54,15 +54,15 @@ fn main() -> () {
     }
 
     bb6 (cleanup): {
-        drop(_7) -> [return: bb7, unwind terminate (panic in a destructor during cleanup)];
+        drop(_7) -> [return: bb7, unwind terminate(cleanup)];
     }
 
     bb7 (cleanup): {
-        drop(_1) -> [return: bb9, unwind terminate (panic in a destructor during cleanup)];
+        drop(_1) -> [return: bb9, unwind terminate(cleanup)];
     }
 
     bb8 (cleanup): {
-        drop(_5) -> [return: bb9, unwind terminate (panic in a destructor during cleanup)];
+        drop(_5) -> [return: bb9, unwind terminate(cleanup)];
     }
 
     bb9 (cleanup): {
diff --git a/tests/mir-opt/box_expr.main.ElaborateDrops.before.panic-unwind.mir b/tests/mir-opt/box_expr.main.ElaborateDrops.before.panic-unwind.mir
index 4cfdc8701c6..4ad1c2de129 100644
--- a/tests/mir-opt/box_expr.main.ElaborateDrops.before.panic-unwind.mir
+++ b/tests/mir-opt/box_expr.main.ElaborateDrops.before.panic-unwind.mir
@@ -54,15 +54,15 @@ fn main() -> () {
     }
 
     bb6 (cleanup): {
-        drop(_7) -> [return: bb7, unwind terminate (panic in a destructor during cleanup)];
+        drop(_7) -> [return: bb7, unwind terminate(cleanup)];
     }
 
     bb7 (cleanup): {
-        drop(_1) -> [return: bb9, unwind terminate (panic in a destructor during cleanup)];
+        drop(_1) -> [return: bb9, unwind terminate(cleanup)];
     }
 
     bb8 (cleanup): {
-        drop(_5) -> [return: bb9, unwind terminate (panic in a destructor during cleanup)];
+        drop(_5) -> [return: bb9, unwind terminate(cleanup)];
     }
 
     bb9 (cleanup): {
diff --git a/tests/mir-opt/building/enum_cast.droppy.built.after.mir b/tests/mir-opt/building/enum_cast.droppy.built.after.mir
index d1f8b8daf74..ea0edb610f5 100644
--- a/tests/mir-opt/building/enum_cast.droppy.built.after.mir
+++ b/tests/mir-opt/building/enum_cast.droppy.built.after.mir
@@ -62,7 +62,7 @@ fn droppy() -> () {
     }
 
     bb4 (cleanup): {
-        drop(_2) -> [return: bb5, unwind terminate (panic in a destructor during cleanup)];
+        drop(_2) -> [return: bb5, unwind terminate(cleanup)];
     }
 
     bb5 (cleanup): {
diff --git a/tests/mir-opt/building/uniform_array_move_out.move_out_by_subslice.built.after.mir b/tests/mir-opt/building/uniform_array_move_out.move_out_by_subslice.built.after.mir
index f7fc1eb7ce3..82424de0392 100644
--- a/tests/mir-opt/building/uniform_array_move_out.move_out_by_subslice.built.after.mir
+++ b/tests/mir-opt/building/uniform_array_move_out.move_out_by_subslice.built.after.mir
@@ -89,15 +89,15 @@ fn move_out_by_subslice() -> () {
     }
 
     bb9 (cleanup): {
-        drop(_1) -> [return: bb12, unwind terminate (panic in a destructor during cleanup)];
+        drop(_1) -> [return: bb12, unwind terminate(cleanup)];
     }
 
     bb10 (cleanup): {
-        drop(_7) -> [return: bb11, unwind terminate (panic in a destructor during cleanup)];
+        drop(_7) -> [return: bb11, unwind terminate(cleanup)];
     }
 
     bb11 (cleanup): {
-        drop(_2) -> [return: bb12, unwind terminate (panic in a destructor during cleanup)];
+        drop(_2) -> [return: bb12, unwind terminate(cleanup)];
     }
 
     bb12 (cleanup): {
diff --git a/tests/mir-opt/building/uniform_array_move_out.move_out_from_end.built.after.mir b/tests/mir-opt/building/uniform_array_move_out.move_out_from_end.built.after.mir
index 95c061dc9fa..0872d1b6ac0 100644
--- a/tests/mir-opt/building/uniform_array_move_out.move_out_from_end.built.after.mir
+++ b/tests/mir-opt/building/uniform_array_move_out.move_out_from_end.built.after.mir
@@ -89,15 +89,15 @@ fn move_out_from_end() -> () {
     }
 
     bb9 (cleanup): {
-        drop(_1) -> [return: bb12, unwind terminate (panic in a destructor during cleanup)];
+        drop(_1) -> [return: bb12, unwind terminate(cleanup)];
     }
 
     bb10 (cleanup): {
-        drop(_7) -> [return: bb11, unwind terminate (panic in a destructor during cleanup)];
+        drop(_7) -> [return: bb11, unwind terminate(cleanup)];
     }
 
     bb11 (cleanup): {
-        drop(_2) -> [return: bb12, unwind terminate (panic in a destructor during cleanup)];
+        drop(_2) -> [return: bb12, unwind terminate(cleanup)];
     }
 
     bb12 (cleanup): {
diff --git a/tests/mir-opt/combine_clone_of_primitives.{impl#0}-clone.InstSimplify.panic-unwind.diff b/tests/mir-opt/combine_clone_of_primitives.{impl#0}-clone.InstSimplify.panic-unwind.diff
index 20f627a567d..f2b87221f2b 100644
--- a/tests/mir-opt/combine_clone_of_primitives.{impl#0}-clone.InstSimplify.panic-unwind.diff
+++ b/tests/mir-opt/combine_clone_of_primitives.{impl#0}-clone.InstSimplify.panic-unwind.diff
@@ -63,7 +63,7 @@
       }
   
       bb4 (cleanup): {
-          drop(_2) -> [return: bb5, unwind terminate (panic in a destructor during cleanup)];
+          drop(_2) -> [return: bb5, unwind terminate(cleanup)];
       }
   
       bb5 (cleanup): {
diff --git a/tests/mir-opt/derefer_inline_test.main.Derefer.panic-abort.diff b/tests/mir-opt/derefer_inline_test.main.Derefer.panic-abort.diff
index b59a377d27c..8ac6acd0e4a 100644
--- a/tests/mir-opt/derefer_inline_test.main.Derefer.panic-abort.diff
+++ b/tests/mir-opt/derefer_inline_test.main.Derefer.panic-abort.diff
@@ -28,7 +28,7 @@
       }
   
       bb4 (cleanup): {
-          drop(_2) -> [return: bb5, unwind terminate (panic in a destructor during cleanup)];
+          drop(_2) -> [return: bb5, unwind terminate(cleanup)];
       }
   
       bb5 (cleanup): {
diff --git a/tests/mir-opt/derefer_inline_test.main.Derefer.panic-unwind.diff b/tests/mir-opt/derefer_inline_test.main.Derefer.panic-unwind.diff
index effecc03738..aa9fcb505e6 100644
--- a/tests/mir-opt/derefer_inline_test.main.Derefer.panic-unwind.diff
+++ b/tests/mir-opt/derefer_inline_test.main.Derefer.panic-unwind.diff
@@ -28,7 +28,7 @@
       }
   
       bb4 (cleanup): {
-          drop(_2) -> [return: bb5, unwind terminate (panic in a destructor during cleanup)];
+          drop(_2) -> [return: bb5, unwind terminate(cleanup)];
       }
   
       bb5 (cleanup): {
diff --git a/tests/mir-opt/generator_storage_dead_unwind.main-{closure#0}.StateTransform.before.panic-unwind.mir b/tests/mir-opt/generator_storage_dead_unwind.main-{closure#0}.StateTransform.before.panic-unwind.mir
index 8ec9c46f95f..6fcceb6c66b 100644
--- a/tests/mir-opt/generator_storage_dead_unwind.main-{closure#0}.StateTransform.before.panic-unwind.mir
+++ b/tests/mir-opt/generator_storage_dead_unwind.main-{closure#0}.StateTransform.before.panic-unwind.mir
@@ -104,7 +104,7 @@ yields ()
 
     bb13 (cleanup): {
         StorageDead(_3);
-        drop(_1) -> [return: bb14, unwind terminate (panic in a destructor during cleanup)];
+        drop(_1) -> [return: bb14, unwind terminate(cleanup)];
     }
 
     bb14 (cleanup): {
@@ -113,6 +113,6 @@ yields ()
 
     bb15 (cleanup): {
         StorageDead(_3);
-        drop(_1) -> [return: bb14, unwind terminate (panic in a destructor during cleanup)];
+        drop(_1) -> [return: bb14, unwind terminate(cleanup)];
     }
 }
diff --git a/tests/mir-opt/inline/asm_unwind.main.Inline.panic-abort.diff b/tests/mir-opt/inline/asm_unwind.main.Inline.panic-abort.diff
index 2371297aefb..aa9429c46d8 100644
--- a/tests/mir-opt/inline/asm_unwind.main.Inline.panic-abort.diff
+++ b/tests/mir-opt/inline/asm_unwind.main.Inline.panic-abort.diff
@@ -17,7 +17,7 @@
           StorageLive(_1);
 -         _1 = foo() -> [return: bb1, unwind unreachable];
 +         StorageLive(_2);
-+         asm!("", options(MAY_UNWIND)) -> [return: bb2, unwind terminate (panic in a function that cannot unwind)];
++         asm!("", options(MAY_UNWIND)) -> [return: bb2, unwind terminate(abi)];
       }
   
       bb1: {
diff --git a/tests/mir-opt/inline/asm_unwind.main.Inline.panic-unwind.diff b/tests/mir-opt/inline/asm_unwind.main.Inline.panic-unwind.diff
index 4c0be81ea26..ea9c360aa7b 100644
--- a/tests/mir-opt/inline/asm_unwind.main.Inline.panic-unwind.diff
+++ b/tests/mir-opt/inline/asm_unwind.main.Inline.panic-unwind.diff
@@ -32,7 +32,7 @@
 +     }
 + 
 +     bb3 (cleanup): {
-+         drop(_2) -> [return: bb4, unwind terminate (panic in a destructor during cleanup)];
++         drop(_2) -> [return: bb4, unwind terminate(cleanup)];
 +     }
 + 
 +     bb4 (cleanup): {
diff --git a/tests/mir-opt/inline/cycle.f.Inline.panic-unwind.diff b/tests/mir-opt/inline/cycle.f.Inline.panic-unwind.diff
index 6e95225a43d..b7fea4f2e14 100644
--- a/tests/mir-opt/inline/cycle.f.Inline.panic-unwind.diff
+++ b/tests/mir-opt/inline/cycle.f.Inline.panic-unwind.diff
@@ -30,7 +30,7 @@
       }
   
       bb3 (cleanup): {
-          drop(_1) -> [return: bb4, unwind terminate (panic in a destructor during cleanup)];
+          drop(_1) -> [return: bb4, unwind terminate(cleanup)];
       }
   
       bb4 (cleanup): {
diff --git a/tests/mir-opt/inline/cycle.g.Inline.panic-unwind.diff b/tests/mir-opt/inline/cycle.g.Inline.panic-unwind.diff
index cd3ea5ebd0e..1fd1014ba1d 100644
--- a/tests/mir-opt/inline/cycle.g.Inline.panic-unwind.diff
+++ b/tests/mir-opt/inline/cycle.g.Inline.panic-unwind.diff
@@ -36,7 +36,7 @@
 +     }
 + 
 +     bb3 (cleanup): {
-+         drop(_2) -> [return: bb4, unwind terminate (panic in a destructor during cleanup)];
++         drop(_2) -> [return: bb4, unwind terminate(cleanup)];
 +     }
 + 
 +     bb4 (cleanup): {
diff --git a/tests/mir-opt/inline/cycle.main.Inline.panic-unwind.diff b/tests/mir-opt/inline/cycle.main.Inline.panic-unwind.diff
index 66ce2f92186..e8299db47db 100644
--- a/tests/mir-opt/inline/cycle.main.Inline.panic-unwind.diff
+++ b/tests/mir-opt/inline/cycle.main.Inline.panic-unwind.diff
@@ -36,7 +36,7 @@
 +     }
 + 
 +     bb3 (cleanup): {
-+         drop(_2) -> [return: bb4, unwind terminate (panic in a destructor during cleanup)];
++         drop(_2) -> [return: bb4, unwind terminate(cleanup)];
 +     }
 + 
 +     bb4 (cleanup): {
diff --git a/tests/mir-opt/inline/dont_ice_on_generic_rust_call.call.Inline.panic-unwind.diff b/tests/mir-opt/inline/dont_ice_on_generic_rust_call.call.Inline.panic-unwind.diff
index daabb0ffc21..b82961c2815 100644
--- a/tests/mir-opt/inline/dont_ice_on_generic_rust_call.call.Inline.panic-unwind.diff
+++ b/tests/mir-opt/inline/dont_ice_on_generic_rust_call.call.Inline.panic-unwind.diff
@@ -27,7 +27,7 @@
       }
   
       bb3 (cleanup): {
-          drop(_1) -> [return: bb4, unwind terminate (panic in a destructor during cleanup)];
+          drop(_1) -> [return: bb4, unwind terminate(cleanup)];
       }
   
       bb4 (cleanup): {
diff --git a/tests/mir-opt/inline/inline_box_fn.call.Inline.panic-unwind.diff b/tests/mir-opt/inline/inline_box_fn.call.Inline.panic-unwind.diff
index b3fee11e7dd..47fd0ed0799 100644
--- a/tests/mir-opt/inline/inline_box_fn.call.Inline.panic-unwind.diff
+++ b/tests/mir-opt/inline/inline_box_fn.call.Inline.panic-unwind.diff
@@ -30,7 +30,7 @@
       }
   
       bb3 (cleanup): {
-          drop(_1) -> [return: bb4, unwind terminate (panic in a destructor during cleanup)];
+          drop(_1) -> [return: bb4, unwind terminate(cleanup)];
       }
   
       bb4 (cleanup): {
diff --git a/tests/mir-opt/inline/inline_diverging.h.Inline.panic-unwind.diff b/tests/mir-opt/inline/inline_diverging.h.Inline.panic-unwind.diff
index e3f5e9810c6..9f8c5806c90 100644
--- a/tests/mir-opt/inline/inline_diverging.h.Inline.panic-unwind.diff
+++ b/tests/mir-opt/inline/inline_diverging.h.Inline.panic-unwind.diff
@@ -54,11 +54,11 @@
 +     }
 + 
 +     bb4 (cleanup): {
-+         drop(_4) -> [return: bb5, unwind terminate (panic in a destructor during cleanup)];
++         drop(_4) -> [return: bb5, unwind terminate(cleanup)];
 +     }
 + 
 +     bb5 (cleanup): {
-+         drop(_2) -> [return: bb6, unwind terminate (panic in a destructor during cleanup)];
++         drop(_2) -> [return: bb6, unwind terminate(cleanup)];
 +     }
 + 
 +     bb6 (cleanup): {
diff --git a/tests/mir-opt/inline/inline_into_box_place.main.Inline.panic-unwind.diff b/tests/mir-opt/inline/inline_into_box_place.main.Inline.panic-unwind.diff
index d017900fc4c..675292f06d6 100644
--- a/tests/mir-opt/inline/inline_into_box_place.main.Inline.panic-unwind.diff
+++ b/tests/mir-opt/inline/inline_into_box_place.main.Inline.panic-unwind.diff
@@ -155,7 +155,7 @@
 -         StorageDead(_1);
 -         return;
 +     bb3 (cleanup): {
-+         drop(_2) -> [return: bb2, unwind terminate (panic in a destructor during cleanup)];
++         drop(_2) -> [return: bb2, unwind terminate(cleanup)];
       }
   
 -     bb4 (cleanup): {
diff --git a/tests/mir-opt/inline/issue_78442.bar.Inline.panic-unwind.diff b/tests/mir-opt/inline/issue_78442.bar.Inline.panic-unwind.diff
index 9042121ea9f..5a946712ea4 100644
--- a/tests/mir-opt/inline/issue_78442.bar.Inline.panic-unwind.diff
+++ b/tests/mir-opt/inline/issue_78442.bar.Inline.panic-unwind.diff
@@ -37,7 +37,7 @@
       }
   
       bb4 (cleanup): {
-          drop(_1) -> [return: bb5, unwind terminate (panic in a destructor during cleanup)];
+          drop(_1) -> [return: bb5, unwind terminate(cleanup)];
       }
   
       bb5 (cleanup): {
diff --git a/tests/mir-opt/inline/issue_78442.bar.RevealAll.panic-unwind.diff b/tests/mir-opt/inline/issue_78442.bar.RevealAll.panic-unwind.diff
index 2a55b018f7c..cbfb39115b3 100644
--- a/tests/mir-opt/inline/issue_78442.bar.RevealAll.panic-unwind.diff
+++ b/tests/mir-opt/inline/issue_78442.bar.RevealAll.panic-unwind.diff
@@ -40,7 +40,7 @@
       }
   
       bb4 (cleanup): {
-          drop(_1) -> [return: bb5, unwind terminate (panic in a destructor during cleanup)];
+          drop(_1) -> [return: bb5, unwind terminate(cleanup)];
       }
   
       bb5 (cleanup): {
diff --git a/tests/mir-opt/inline/unsized_argument.caller.Inline.diff b/tests/mir-opt/inline/unsized_argument.caller.Inline.diff
index 0cddc5a36b1..ab81f707148 100644
--- a/tests/mir-opt/inline/unsized_argument.caller.Inline.diff
+++ b/tests/mir-opt/inline/unsized_argument.caller.Inline.diff
@@ -40,7 +40,7 @@
   
       bb4 (cleanup): {
           _8 = &mut _3;
-          _9 = <Box<[i32]> as Drop>::drop(move _8) -> [return: bb1, unwind terminate (panic in a destructor during cleanup)];
+          _9 = <Box<[i32]> as Drop>::drop(move _8) -> [return: bb1, unwind terminate(cleanup)];
       }
   }
   
diff --git a/tests/mir-opt/issue_41110.main.ElaborateDrops.panic-abort.diff b/tests/mir-opt/issue_41110.main.ElaborateDrops.panic-abort.diff
index 4f7ca616792..4469270a9b2 100644
--- a/tests/mir-opt/issue_41110.main.ElaborateDrops.panic-abort.diff
+++ b/tests/mir-opt/issue_41110.main.ElaborateDrops.panic-abort.diff
@@ -40,17 +40,17 @@
       }
   
       bb3 (cleanup): {
--         drop(_3) -> [return: bb5, unwind terminate (panic in a destructor during cleanup)];
+-         drop(_3) -> [return: bb5, unwind terminate(cleanup)];
 +         goto -> bb5;
       }
   
       bb4 (cleanup): {
--         drop(_4) -> [return: bb5, unwind terminate (panic in a destructor during cleanup)];
+-         drop(_4) -> [return: bb5, unwind terminate(cleanup)];
 +         goto -> bb5;
       }
   
       bb5 (cleanup): {
--         drop(_2) -> [return: bb6, unwind terminate (panic in a destructor during cleanup)];
+-         drop(_2) -> [return: bb6, unwind terminate(cleanup)];
 +         goto -> bb8;
       }
   
@@ -59,7 +59,7 @@
 +     }
 + 
 +     bb7 (cleanup): {
-+         drop(_2) -> [return: bb6, unwind terminate (panic in a destructor during cleanup)];
++         drop(_2) -> [return: bb6, unwind terminate(cleanup)];
 +     }
 + 
 +     bb8 (cleanup): {
diff --git a/tests/mir-opt/issue_41110.main.ElaborateDrops.panic-unwind.diff b/tests/mir-opt/issue_41110.main.ElaborateDrops.panic-unwind.diff
index 4f7ca616792..4469270a9b2 100644
--- a/tests/mir-opt/issue_41110.main.ElaborateDrops.panic-unwind.diff
+++ b/tests/mir-opt/issue_41110.main.ElaborateDrops.panic-unwind.diff
@@ -40,17 +40,17 @@
       }
   
       bb3 (cleanup): {
--         drop(_3) -> [return: bb5, unwind terminate (panic in a destructor during cleanup)];
+-         drop(_3) -> [return: bb5, unwind terminate(cleanup)];
 +         goto -> bb5;
       }
   
       bb4 (cleanup): {
--         drop(_4) -> [return: bb5, unwind terminate (panic in a destructor during cleanup)];
+-         drop(_4) -> [return: bb5, unwind terminate(cleanup)];
 +         goto -> bb5;
       }
   
       bb5 (cleanup): {
--         drop(_2) -> [return: bb6, unwind terminate (panic in a destructor during cleanup)];
+-         drop(_2) -> [return: bb6, unwind terminate(cleanup)];
 +         goto -> bb8;
       }
   
@@ -59,7 +59,7 @@
 +     }
 + 
 +     bb7 (cleanup): {
-+         drop(_2) -> [return: bb6, unwind terminate (panic in a destructor during cleanup)];
++         drop(_2) -> [return: bb6, unwind terminate(cleanup)];
 +     }
 + 
 +     bb8 (cleanup): {
diff --git a/tests/mir-opt/issue_41110.test.ElaborateDrops.panic-abort.diff b/tests/mir-opt/issue_41110.test.ElaborateDrops.panic-abort.diff
index 0f38e3961a6..78184f6aeeb 100644
--- a/tests/mir-opt/issue_41110.test.ElaborateDrops.panic-abort.diff
+++ b/tests/mir-opt/issue_41110.test.ElaborateDrops.panic-abort.diff
@@ -47,7 +47,7 @@
   
       bb3 (cleanup): {
           _2 = move _5;
--         drop(_5) -> [return: bb8, unwind terminate (panic in a destructor during cleanup)];
+-         drop(_5) -> [return: bb8, unwind terminate(cleanup)];
 +         goto -> bb8;
       }
   
@@ -70,17 +70,17 @@
       }
   
       bb7 (cleanup): {
--         drop(_4) -> [return: bb8, unwind terminate (panic in a destructor during cleanup)];
+-         drop(_4) -> [return: bb8, unwind terminate(cleanup)];
 +         goto -> bb8;
       }
   
       bb8 (cleanup): {
--         drop(_2) -> [return: bb9, unwind terminate (panic in a destructor during cleanup)];
+-         drop(_2) -> [return: bb9, unwind terminate(cleanup)];
 +         goto -> bb9;
       }
   
       bb9 (cleanup): {
--         drop(_1) -> [return: bb10, unwind terminate (panic in a destructor during cleanup)];
+-         drop(_1) -> [return: bb10, unwind terminate(cleanup)];
 +         goto -> bb12;
       }
   
@@ -89,7 +89,7 @@
 +     }
 + 
 +     bb11 (cleanup): {
-+         drop(_1) -> [return: bb10, unwind terminate (panic in a destructor during cleanup)];
++         drop(_1) -> [return: bb10, unwind terminate(cleanup)];
 +     }
 + 
 +     bb12 (cleanup): {
diff --git a/tests/mir-opt/issue_41110.test.ElaborateDrops.panic-unwind.diff b/tests/mir-opt/issue_41110.test.ElaborateDrops.panic-unwind.diff
index 8da15ec9e23..688887c3c1f 100644
--- a/tests/mir-opt/issue_41110.test.ElaborateDrops.panic-unwind.diff
+++ b/tests/mir-opt/issue_41110.test.ElaborateDrops.panic-unwind.diff
@@ -47,7 +47,7 @@
   
       bb3 (cleanup): {
           _2 = move _5;
--         drop(_5) -> [return: bb8, unwind terminate (panic in a destructor during cleanup)];
+-         drop(_5) -> [return: bb8, unwind terminate(cleanup)];
 +         goto -> bb8;
       }
   
@@ -70,17 +70,17 @@
       }
   
       bb7 (cleanup): {
--         drop(_4) -> [return: bb8, unwind terminate (panic in a destructor during cleanup)];
+-         drop(_4) -> [return: bb8, unwind terminate(cleanup)];
 +         goto -> bb8;
       }
   
       bb8 (cleanup): {
--         drop(_2) -> [return: bb9, unwind terminate (panic in a destructor during cleanup)];
+-         drop(_2) -> [return: bb9, unwind terminate(cleanup)];
 +         goto -> bb9;
       }
   
       bb9 (cleanup): {
--         drop(_1) -> [return: bb10, unwind terminate (panic in a destructor during cleanup)];
+-         drop(_1) -> [return: bb10, unwind terminate(cleanup)];
 +         goto -> bb12;
       }
   
@@ -89,7 +89,7 @@
 +     }
 + 
 +     bb11 (cleanup): {
-+         drop(_1) -> [return: bb10, unwind terminate (panic in a destructor during cleanup)];
++         drop(_1) -> [return: bb10, unwind terminate(cleanup)];
 +     }
 + 
 +     bb12 (cleanup): {
diff --git a/tests/mir-opt/issue_41888.main.ElaborateDrops.panic-abort.diff b/tests/mir-opt/issue_41888.main.ElaborateDrops.panic-abort.diff
index 562e684f29f..b57fe348c2d 100644
--- a/tests/mir-opt/issue_41888.main.ElaborateDrops.panic-abort.diff
+++ b/tests/mir-opt/issue_41888.main.ElaborateDrops.panic-abort.diff
@@ -58,7 +58,7 @@
 +         _8 = const true;
 +         _9 = const true;
           _1 = move _3;
--         drop(_3) -> [return: bb11, unwind terminate (panic in a destructor during cleanup)];
+-         drop(_3) -> [return: bb11, unwind terminate(cleanup)];
 +         goto -> bb11;
       }
   
@@ -102,7 +102,7 @@
       }
   
       bb11 (cleanup): {
--         drop(_1) -> [return: bb12, unwind terminate (panic in a destructor during cleanup)];
+-         drop(_1) -> [return: bb12, unwind terminate(cleanup)];
 +         goto -> bb12;
       }
   
@@ -124,7 +124,7 @@
 +     }
 + 
 +     bb16 (cleanup): {
-+         drop(_1) -> [return: bb12, unwind terminate (panic in a destructor during cleanup)];
++         drop(_1) -> [return: bb12, unwind terminate(cleanup)];
 +     }
 + 
 +     bb17: {
diff --git a/tests/mir-opt/issue_41888.main.ElaborateDrops.panic-unwind.diff b/tests/mir-opt/issue_41888.main.ElaborateDrops.panic-unwind.diff
index c6cc80c09c0..2156850e38c 100644
--- a/tests/mir-opt/issue_41888.main.ElaborateDrops.panic-unwind.diff
+++ b/tests/mir-opt/issue_41888.main.ElaborateDrops.panic-unwind.diff
@@ -58,7 +58,7 @@
 +         _8 = const true;
 +         _9 = const true;
           _1 = move _3;
--         drop(_3) -> [return: bb11, unwind terminate (panic in a destructor during cleanup)];
+-         drop(_3) -> [return: bb11, unwind terminate(cleanup)];
 +         goto -> bb11;
       }
   
@@ -102,7 +102,7 @@
       }
   
       bb11 (cleanup): {
--         drop(_1) -> [return: bb12, unwind terminate (panic in a destructor during cleanup)];
+-         drop(_1) -> [return: bb12, unwind terminate(cleanup)];
 +         goto -> bb12;
       }
   
@@ -124,7 +124,7 @@
 +     }
 + 
 +     bb16 (cleanup): {
-+         drop(_1) -> [return: bb12, unwind terminate (panic in a destructor during cleanup)];
++         drop(_1) -> [return: bb12, unwind terminate(cleanup)];
 +     }
 + 
 +     bb17: {
diff --git a/tests/mir-opt/issue_62289.test.ElaborateDrops.before.panic-abort.mir b/tests/mir-opt/issue_62289.test.ElaborateDrops.before.panic-abort.mir
index 151571f57eb..73462967850 100644
--- a/tests/mir-opt/issue_62289.test.ElaborateDrops.before.panic-abort.mir
+++ b/tests/mir-opt/issue_62289.test.ElaborateDrops.before.panic-abort.mir
@@ -100,11 +100,11 @@ fn test() -> Option<Box<u32>> {
     }
 
     bb11 (cleanup): {
-        drop(_1) -> [return: bb13, unwind terminate (panic in a destructor during cleanup)];
+        drop(_1) -> [return: bb13, unwind terminate(cleanup)];
     }
 
     bb12 (cleanup): {
-        drop(_5) -> [return: bb13, unwind terminate (panic in a destructor during cleanup)];
+        drop(_5) -> [return: bb13, unwind terminate(cleanup)];
     }
 
     bb13 (cleanup): {
diff --git a/tests/mir-opt/issue_62289.test.ElaborateDrops.before.panic-unwind.mir b/tests/mir-opt/issue_62289.test.ElaborateDrops.before.panic-unwind.mir
index bda3080edb9..8264e2cabbc 100644
--- a/tests/mir-opt/issue_62289.test.ElaborateDrops.before.panic-unwind.mir
+++ b/tests/mir-opt/issue_62289.test.ElaborateDrops.before.panic-unwind.mir
@@ -100,11 +100,11 @@ fn test() -> Option<Box<u32>> {
     }
 
     bb11 (cleanup): {
-        drop(_1) -> [return: bb13, unwind terminate (panic in a destructor during cleanup)];
+        drop(_1) -> [return: bb13, unwind terminate(cleanup)];
     }
 
     bb12 (cleanup): {
-        drop(_5) -> [return: bb13, unwind terminate (panic in a destructor during cleanup)];
+        drop(_5) -> [return: bb13, unwind terminate(cleanup)];
     }
 
     bb13 (cleanup): {
diff --git a/tests/mir-opt/issue_91633.bar.built.after.mir b/tests/mir-opt/issue_91633.bar.built.after.mir
index 6aa49aab20e..cce1a1fd2ef 100644
--- a/tests/mir-opt/issue_91633.bar.built.after.mir
+++ b/tests/mir-opt/issue_91633.bar.built.after.mir
@@ -28,7 +28,7 @@ fn bar(_1: Box<[T]>) -> () {
     }
 
     bb3 (cleanup): {
-        drop(_1) -> [return: bb4, unwind terminate (panic in a destructor during cleanup)];
+        drop(_1) -> [return: bb4, unwind terminate(cleanup)];
     }
 
     bb4 (cleanup): {
diff --git a/tests/mir-opt/issue_91633.foo.built.after.mir b/tests/mir-opt/issue_91633.foo.built.after.mir
index 2cf68321743..a66769f0d11 100644
--- a/tests/mir-opt/issue_91633.foo.built.after.mir
+++ b/tests/mir-opt/issue_91633.foo.built.after.mir
@@ -45,7 +45,7 @@ fn foo(_1: Box<[T]>) -> T {
     }
 
     bb5 (cleanup): {
-        drop(_1) -> [return: bb6, unwind terminate (panic in a destructor during cleanup)];
+        drop(_1) -> [return: bb6, unwind terminate(cleanup)];
     }
 
     bb6 (cleanup): {
diff --git a/tests/mir-opt/match_arm_scopes.complicated_match.panic-abort.SimplifyCfg-initial.after-ElaborateDrops.after.diff b/tests/mir-opt/match_arm_scopes.complicated_match.panic-abort.SimplifyCfg-initial.after-ElaborateDrops.after.diff
index 9452ba7e6bc..3e817ff433b 100644
--- a/tests/mir-opt/match_arm_scopes.complicated_match.panic-abort.SimplifyCfg-initial.after-ElaborateDrops.after.diff
+++ b/tests/mir-opt/match_arm_scopes.complicated_match.panic-abort.SimplifyCfg-initial.after-ElaborateDrops.after.diff
@@ -243,7 +243,7 @@
       }
   
 -     bb25 (cleanup): {
--         drop(_2) -> [return: bb26, unwind terminate (panic in a destructor during cleanup)];
+-         drop(_2) -> [return: bb26, unwind terminate(cleanup)];
 +     bb22 (cleanup): {
 +         goto -> bb27;
       }
diff --git a/tests/mir-opt/match_arm_scopes.complicated_match.panic-unwind.SimplifyCfg-initial.after-ElaborateDrops.after.diff b/tests/mir-opt/match_arm_scopes.complicated_match.panic-unwind.SimplifyCfg-initial.after-ElaborateDrops.after.diff
index 9452ba7e6bc..3e817ff433b 100644
--- a/tests/mir-opt/match_arm_scopes.complicated_match.panic-unwind.SimplifyCfg-initial.after-ElaborateDrops.after.diff
+++ b/tests/mir-opt/match_arm_scopes.complicated_match.panic-unwind.SimplifyCfg-initial.after-ElaborateDrops.after.diff
@@ -243,7 +243,7 @@
       }
   
 -     bb25 (cleanup): {
--         drop(_2) -> [return: bb26, unwind terminate (panic in a destructor during cleanup)];
+-         drop(_2) -> [return: bb26, unwind terminate(cleanup)];
 +     bb22 (cleanup): {
 +         goto -> bb27;
       }
diff --git a/tests/mir-opt/no_spurious_drop_after_call.main.ElaborateDrops.before.panic-abort.mir b/tests/mir-opt/no_spurious_drop_after_call.main.ElaborateDrops.before.panic-abort.mir
index 51a009056d7..99a7a6b6154 100644
--- a/tests/mir-opt/no_spurious_drop_after_call.main.ElaborateDrops.before.panic-abort.mir
+++ b/tests/mir-opt/no_spurious_drop_after_call.main.ElaborateDrops.before.panic-abort.mir
@@ -31,7 +31,7 @@ fn main() -> () {
     }
 
     bb3 (cleanup): {
-        drop(_2) -> [return: bb4, unwind terminate (panic in a destructor during cleanup)];
+        drop(_2) -> [return: bb4, unwind terminate(cleanup)];
     }
 
     bb4 (cleanup): {
diff --git a/tests/mir-opt/no_spurious_drop_after_call.main.ElaborateDrops.before.panic-unwind.mir b/tests/mir-opt/no_spurious_drop_after_call.main.ElaborateDrops.before.panic-unwind.mir
index 95820cfafbc..7364b329e12 100644
--- a/tests/mir-opt/no_spurious_drop_after_call.main.ElaborateDrops.before.panic-unwind.mir
+++ b/tests/mir-opt/no_spurious_drop_after_call.main.ElaborateDrops.before.panic-unwind.mir
@@ -31,7 +31,7 @@ fn main() -> () {
     }
 
     bb3 (cleanup): {
-        drop(_2) -> [return: bb4, unwind terminate (panic in a destructor during cleanup)];
+        drop(_2) -> [return: bb4, unwind terminate(cleanup)];
     }
 
     bb4 (cleanup): {
diff --git a/tests/mir-opt/packed_struct_drop_aligned.main.SimplifyCfg-elaborate-drops.after.panic-unwind.mir b/tests/mir-opt/packed_struct_drop_aligned.main.SimplifyCfg-elaborate-drops.after.panic-unwind.mir
index 9a43756cbc0..0ef19180459 100644
--- a/tests/mir-opt/packed_struct_drop_aligned.main.SimplifyCfg-elaborate-drops.after.panic-unwind.mir
+++ b/tests/mir-opt/packed_struct_drop_aligned.main.SimplifyCfg-elaborate-drops.after.panic-unwind.mir
@@ -33,7 +33,7 @@ fn main() -> () {
 
     bb1 (cleanup): {
         (_1.0: Aligned) = move _4;
-        drop(_1) -> [return: bb3, unwind terminate (panic in a destructor during cleanup)];
+        drop(_1) -> [return: bb3, unwind terminate(cleanup)];
     }
 
     bb2: {
diff --git a/tests/mir-opt/pre-codegen/loops.filter_mapped.PreCodegen.after.mir b/tests/mir-opt/pre-codegen/loops.filter_mapped.PreCodegen.after.mir
index d7059d21488..4db829a5ec3 100644
--- a/tests/mir-opt/pre-codegen/loops.filter_mapped.PreCodegen.after.mir
+++ b/tests/mir-opt/pre-codegen/loops.filter_mapped.PreCodegen.after.mir
@@ -83,7 +83,7 @@ fn filter_mapped(_1: impl Iterator<Item = T>, _2: impl Fn(T) -> Option<U>) -> ()
     }
 
     bb9 (cleanup): {
-        drop(_5) -> [return: bb10, unwind terminate (panic in a destructor during cleanup)];
+        drop(_5) -> [return: bb10, unwind terminate(cleanup)];
     }
 
     bb10 (cleanup): {
diff --git a/tests/mir-opt/pre-codegen/loops.mapped.PreCodegen.after.mir b/tests/mir-opt/pre-codegen/loops.mapped.PreCodegen.after.mir
index 9a10f5cb575..c30df7425d2 100644
--- a/tests/mir-opt/pre-codegen/loops.mapped.PreCodegen.after.mir
+++ b/tests/mir-opt/pre-codegen/loops.mapped.PreCodegen.after.mir
@@ -75,7 +75,7 @@ fn mapped(_1: impl Iterator<Item = T>, _2: impl Fn(T) -> U) -> () {
     }
 
     bb9 (cleanup): {
-        drop(_5) -> [return: bb10, unwind terminate (panic in a destructor during cleanup)];
+        drop(_5) -> [return: bb10, unwind terminate(cleanup)];
     }
 
     bb10 (cleanup): {
diff --git a/tests/mir-opt/pre-codegen/loops.vec_move.PreCodegen.after.mir b/tests/mir-opt/pre-codegen/loops.vec_move.PreCodegen.after.mir
index 431661af705..cb29473d762 100644
--- a/tests/mir-opt/pre-codegen/loops.vec_move.PreCodegen.after.mir
+++ b/tests/mir-opt/pre-codegen/loops.vec_move.PreCodegen.after.mir
@@ -67,7 +67,7 @@ fn vec_move(_1: Vec<impl Sized>) -> () {
     }
 
     bb9 (cleanup): {
-        drop(_3) -> [return: bb10, unwind terminate (panic in a destructor during cleanup)];
+        drop(_3) -> [return: bb10, unwind terminate(cleanup)];
     }
 
     bb10 (cleanup): {
diff --git a/tests/mir-opt/pre-codegen/range_iter.forward_loop.PreCodegen.after.panic-unwind.mir b/tests/mir-opt/pre-codegen/range_iter.forward_loop.PreCodegen.after.panic-unwind.mir
index 7cada9c148d..35f7356d47a 100644
--- a/tests/mir-opt/pre-codegen/range_iter.forward_loop.PreCodegen.after.panic-unwind.mir
+++ b/tests/mir-opt/pre-codegen/range_iter.forward_loop.PreCodegen.after.panic-unwind.mir
@@ -127,7 +127,7 @@ fn forward_loop(_1: u32, _2: u32, _3: impl Fn(u32)) -> () {
     }
 
     bb11 (cleanup): {
-        drop(_3) -> [return: bb12, unwind terminate (panic in a destructor during cleanup)];
+        drop(_3) -> [return: bb12, unwind terminate(cleanup)];
     }
 
     bb12 (cleanup): {
diff --git a/tests/mir-opt/pre-codegen/range_iter.inclusive_loop.PreCodegen.after.panic-unwind.mir b/tests/mir-opt/pre-codegen/range_iter.inclusive_loop.PreCodegen.after.panic-unwind.mir
index ef1f934c52b..a677e8b439f 100644
--- a/tests/mir-opt/pre-codegen/range_iter.inclusive_loop.PreCodegen.after.panic-unwind.mir
+++ b/tests/mir-opt/pre-codegen/range_iter.inclusive_loop.PreCodegen.after.panic-unwind.mir
@@ -82,7 +82,7 @@ fn inclusive_loop(_1: u32, _2: u32, _3: impl Fn(u32)) -> () {
     }
 
     bb8 (cleanup): {
-        drop(_3) -> [return: bb9, unwind terminate (panic in a destructor during cleanup)];
+        drop(_3) -> [return: bb9, unwind terminate(cleanup)];
     }
 
     bb9 (cleanup): {
diff --git a/tests/mir-opt/pre-codegen/slice_iter.enumerated_loop.PreCodegen.after.panic-unwind.mir b/tests/mir-opt/pre-codegen/slice_iter.enumerated_loop.PreCodegen.after.panic-unwind.mir
index b9636712f82..3d76bab7ce7 100644
--- a/tests/mir-opt/pre-codegen/slice_iter.enumerated_loop.PreCodegen.after.panic-unwind.mir
+++ b/tests/mir-opt/pre-codegen/slice_iter.enumerated_loop.PreCodegen.after.panic-unwind.mir
@@ -195,7 +195,7 @@ fn enumerated_loop(_1: &[T], _2: impl Fn(usize, &T)) -> () {
     }
 
     bb11 (cleanup): {
-        drop(_2) -> [return: bb12, unwind terminate (panic in a destructor during cleanup)];
+        drop(_2) -> [return: bb12, unwind terminate(cleanup)];
     }
 
     bb12 (cleanup): {
diff --git a/tests/mir-opt/pre-codegen/slice_iter.forward_loop.PreCodegen.after.panic-unwind.mir b/tests/mir-opt/pre-codegen/slice_iter.forward_loop.PreCodegen.after.panic-unwind.mir
index 0f323a56e61..e8586cec981 100644
--- a/tests/mir-opt/pre-codegen/slice_iter.forward_loop.PreCodegen.after.panic-unwind.mir
+++ b/tests/mir-opt/pre-codegen/slice_iter.forward_loop.PreCodegen.after.panic-unwind.mir
@@ -182,7 +182,7 @@ fn forward_loop(_1: &[T], _2: impl Fn(&T)) -> () {
     }
 
     bb11 (cleanup): {
-        drop(_2) -> [return: bb12, unwind terminate (panic in a destructor during cleanup)];
+        drop(_2) -> [return: bb12, unwind terminate(cleanup)];
     }
 
     bb12 (cleanup): {
diff --git a/tests/mir-opt/pre-codegen/slice_iter.range_loop.PreCodegen.after.panic-unwind.mir b/tests/mir-opt/pre-codegen/slice_iter.range_loop.PreCodegen.after.panic-unwind.mir
index 96160b272b9..8bd072fd625 100644
--- a/tests/mir-opt/pre-codegen/slice_iter.range_loop.PreCodegen.after.panic-unwind.mir
+++ b/tests/mir-opt/pre-codegen/slice_iter.range_loop.PreCodegen.after.panic-unwind.mir
@@ -143,7 +143,7 @@ fn range_loop(_1: &[T], _2: impl Fn(usize, &T)) -> () {
     }
 
     bb12 (cleanup): {
-        drop(_2) -> [return: bb13, unwind terminate (panic in a destructor during cleanup)];
+        drop(_2) -> [return: bb13, unwind terminate(cleanup)];
     }
 
     bb13 (cleanup): {
diff --git a/tests/mir-opt/pre-codegen/slice_iter.reverse_loop.PreCodegen.after.panic-unwind.mir b/tests/mir-opt/pre-codegen/slice_iter.reverse_loop.PreCodegen.after.panic-unwind.mir
index 67d8442ab20..3cdc49f6056 100644
--- a/tests/mir-opt/pre-codegen/slice_iter.reverse_loop.PreCodegen.after.panic-unwind.mir
+++ b/tests/mir-opt/pre-codegen/slice_iter.reverse_loop.PreCodegen.after.panic-unwind.mir
@@ -196,7 +196,7 @@ fn reverse_loop(_1: &[T], _2: impl Fn(&T)) -> () {
     }
 
     bb11 (cleanup): {
-        drop(_2) -> [return: bb12, unwind terminate (panic in a destructor during cleanup)];
+        drop(_2) -> [return: bb12, unwind terminate(cleanup)];
     }
 
     bb12 (cleanup): {
diff --git a/tests/mir-opt/retag.main.SimplifyCfg-elaborate-drops.after.panic-unwind.mir b/tests/mir-opt/retag.main.SimplifyCfg-elaborate-drops.after.panic-unwind.mir
index 09ff59ffa21..7d3346faba6 100644
--- a/tests/mir-opt/retag.main.SimplifyCfg-elaborate-drops.after.panic-unwind.mir
+++ b/tests/mir-opt/retag.main.SimplifyCfg-elaborate-drops.after.panic-unwind.mir
@@ -167,11 +167,11 @@ fn main() -> () {
     }
 
     bb7 (cleanup): {
-        drop(_21) -> [return: bb9, unwind terminate (panic in a destructor during cleanup)];
+        drop(_21) -> [return: bb9, unwind terminate(cleanup)];
     }
 
     bb8 (cleanup): {
-        drop(_5) -> [return: bb9, unwind terminate (panic in a destructor during cleanup)];
+        drop(_5) -> [return: bb9, unwind terminate(cleanup)];
     }
 
     bb9 (cleanup): {
diff --git a/tests/mir-opt/slice_drop_shim.core.ptr-drop_in_place.[String].AddMovesForPackedDrops.before.mir b/tests/mir-opt/slice_drop_shim.core.ptr-drop_in_place.[String].AddMovesForPackedDrops.before.mir
index 8d9f8985578..3a8b457a7a1 100644
--- a/tests/mir-opt/slice_drop_shim.core.ptr-drop_in_place.[String].AddMovesForPackedDrops.before.mir
+++ b/tests/mir-opt/slice_drop_shim.core.ptr-drop_in_place.[String].AddMovesForPackedDrops.before.mir
@@ -24,7 +24,7 @@ fn std::ptr::drop_in_place(_1: *mut [String]) -> () {
     bb3 (cleanup): {
         _4 = &raw mut (*_1)[_3];
         _3 = Add(move _3, const 1_usize);
-        drop((*_4)) -> [return: bb4, unwind terminate (panic in a destructor during cleanup)];
+        drop((*_4)) -> [return: bb4, unwind terminate(cleanup)];
     }
 
     bb4 (cleanup): {
diff --git a/tests/mir-opt/unusual_item_types.core.ptr-drop_in_place.Vec_i32_.AddMovesForPackedDrops.before.mir b/tests/mir-opt/unusual_item_types.core.ptr-drop_in_place.Vec_i32_.AddMovesForPackedDrops.before.mir
index 3768d34dd8e..b5879418355 100644
--- a/tests/mir-opt/unusual_item_types.core.ptr-drop_in_place.Vec_i32_.AddMovesForPackedDrops.before.mir
+++ b/tests/mir-opt/unusual_item_types.core.ptr-drop_in_place.Vec_i32_.AddMovesForPackedDrops.before.mir
@@ -22,7 +22,7 @@ fn std::ptr::drop_in_place(_1: *mut Vec<i32>) -> () {
     }
 
     bb4 (cleanup): {
-        drop(((*_1).0: alloc::raw_vec::RawVec<i32>)) -> [return: bb2, unwind terminate (panic in a destructor during cleanup)];
+        drop(((*_1).0: alloc::raw_vec::RawVec<i32>)) -> [return: bb2, unwind terminate(cleanup)];
     }
 
     bb5: {