aboutsummaryrefslogtreecommitdiffstats
path: root/libjulia/backends/evm/EVMAssembly.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'libjulia/backends/evm/EVMAssembly.cpp')
-rw-r--r--libjulia/backends/evm/EVMAssembly.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/libjulia/backends/evm/EVMAssembly.cpp b/libjulia/backends/evm/EVMAssembly.cpp
index a8019e86..a24d9779 100644
--- a/libjulia/backends/evm/EVMAssembly.cpp
+++ b/libjulia/backends/evm/EVMAssembly.cpp
@@ -134,12 +134,12 @@ void EVMAssembly::appendJumpsub(AbstractAssembly::LabelID _labelId, int _argumen
m_stackHeight += _returns - _arguments;
}
-void EVMAssembly::appendReturnsub(int _returns)
+void EVMAssembly::appendReturnsub(int _returns, int _stackDiffAfter)
{
solAssert(m_evm15, "RETURNSUB used for EVM 1.0");
solAssert(_returns >= 0, "");
m_bytecode.push_back(byte(solidity::Instruction::RETURNSUB));
- m_stackHeight -= _returns;
+ m_stackHeight += _stackDiffAfter - _returns;
}
eth::LinkerObject EVMAssembly::finalize()