Fix returning code size in Yul Ewasm interpreter

This commit is contained in:
Alex Beregszaszi 2019-12-18 14:43:26 +00:00
parent b74f357c5e
commit 9f1e8086bb

View File

@ -215,7 +215,7 @@ u256 EWasmBuiltinInterpreter::evalBuiltin(YulString _fun, vector<u256> const& _a
return 0; return 0;
} }
else if (_fun == "eth.getCodeSize"_yulstring) else if (_fun == "eth.getCodeSize"_yulstring)
return writeU256(arg[0], m_state.code.size()); return m_state.code.size();
else if (_fun == "eth.getBlockCoinbase"_yulstring) else if (_fun == "eth.getBlockCoinbase"_yulstring)
return writeAddress(arg[0], m_state.coinbase); return writeAddress(arg[0], m_state.coinbase);
else if (_fun == "eth.create"_yulstring) else if (_fun == "eth.create"_yulstring)