mirror of
https://github.com/pezkuwichain/revive.git
synced 2026-10-31 07:59:52 +00:00
revive-yul: fix the code block exit (#414)
This PR fixes the missing `STOP` instruction at the end of `code` blocks. --------- Signed-off-by: xermicus <bigcyrill@hotmail.com>
This commit is contained in:
1 parent
dd48baadc7
commit
a1090cfa5a
3 files changed
+105
No files matched your search
@@ -64,6 +64,9 @@ impl PolkaVMWriteLLVM for Code {
|
||||
fn into_llvm(self, context: &mut PolkaVMContext) -> anyhow::Result<()> {
|
||||
self.block.into_llvm(context)?;
|
||||
|
||||
// The EVM lets the code return implicitly.
|
||||
revive_llvm_context::polkavm_evm_return::stop(context)?;
|
||||
|
||||
Ok(())
|
||||
}
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user