Closed axic closed 6 years ago
Related https://github.com/ethereum/EIPs/issues/62. It could also be replaced with special LOGs
, which are not rolled back at execution errors. See https://github.com/ethereum/EIPs/issues/120 for an implementation of moving LOGs to storage.
why not just use return
?
Assuming we change return so that the value is not rolled back on a VM error that could work. However that introduces a discrepancy with how EVM expects it.
Abort execution and store a reason.
Parameters
reasonCode
i32 the reason codedescriptionOffset
i32 the memory offset to load the reason text fromdescriptionLength
i32 the length of the reason text (limited to 32 bytes)Returns
nothing