Refactor & fixup interpreter implementation of tail calls

This commit is contained in:
Maybe Waffle
2024-03-15 15:08:20 +00:00
committed by Maybe Lapkin
parent 30b18d7c36
commit cda25e56c8
4 changed files with 162 additions and 70 deletions

View File

@@ -32,7 +32,7 @@ impl<'tcx, M: Machine<'tcx>> InterpCx<'tcx, M> {
// We are unwinding and this fn has no cleanup code.
// Just go on unwinding.
trace!("unwinding: skipping frame");
self.pop_stack_frame(/* unwinding */ true)?;
self.return_from_current_stack_frame(/* unwinding */ true)?;
return Ok(true);
};
let basic_block = &self.body().basic_blocks[loc.block];