@@ -135,6 +135,7 @@ pub trait EvalContextExt<'a, 'mir, 'tcx: 'a + 'mir>: crate::MiriEvalContextExt<'
135135 // 'payload'. This should help catch some basic errors in
136136 // the caller of this function, even in abort mode
137137 if this. tcx . tcx . sess . panic_strategy ( ) == PanicStrategy :: Abort {
138+ // FIXME: Actually print out the payload here
138139 return err ! ( MachineError ( "the evaluated program abort-panicked" . to_string( ) ) ) ;
139140 }
140141
@@ -1056,9 +1057,6 @@ fn unwind_stack<'a, 'mir, 'tcx>(
10561057 payload_data_ptr : Scalar < Borrow > ,
10571058 payload_vtable_ptr : Scalar < Borrow >
10581059) -> EvalResult < ' tcx > {
1059-
1060- let mut found = false ;
1061-
10621060 while !this. stack ( ) . is_empty ( ) {
10631061 // When '__rust_maybe_catch_panic' is called, it marks is frame
10641062 // with 'catch_panic'. When we find this marker, we've found
@@ -1087,9 +1085,8 @@ fn unwind_stack<'a, 'mir, 'tcx>(
10871085 // We're done - continue execution in the frame of the function
10881086 // that called '__rust_maybe_catch_panic,'
10891087 this. goto_block ( Some ( ret) ) ?;
1090- found = true ;
10911088
1092- break ;
1089+ return Ok ( ( ) )
10931090 } else {
10941091 // This frame is above our target frame on the call stack.
10951092 // We pop it off the stack, running its 'unwind' block if applicable
@@ -1118,9 +1115,7 @@ fn unwind_stack<'a, 'mir, 'tcx>(
11181115 }
11191116 }
11201117
1121- if !found {
1122- // The 'start_fn' lang item should always install a panic handler
1123- return err ! ( Unreachable ) ;
1124- }
1125- return Ok ( ( ) )
1118+ // We should never get here:
1119+ // The 'start_fn' lang item should always install a panic handler
1120+ return err ! ( Unreachable ) ;
11261121}
0 commit comments