Skip to content
This repository was archived by the owner on Apr 8, 2026. It is now read-only.

Commit 174f61e

Browse files
committed
Add EVMC_INSUFFICIENT_BALANCE error to evmc_status_code
1 parent 88323ca commit 174f61e

File tree

3 files changed

+8
-0
lines changed

3 files changed

+8
-0
lines changed

bindings/go/evmc/evmc.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -118,6 +118,8 @@ func (err Error) Error() string {
118118
return "evmc: the WebAssembly unreachable instruction has been hit during execution"
119119
case C.EVMC_WASM_TRAP:
120120
return "evmc: a WebAssembly trap has been hit during execution"
121+
case C.EVMC_INSUFFICIENT_BALANCE:
122+
return "evmc: insufficient balance"
121123
case C.EVMC_REJECTED:
122124
return "evmc: rejected"
123125
}

include/evmc/evmc.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -295,6 +295,9 @@ enum evmc_status_code
295295
*/
296296
EVMC_WASM_TRAP = 16,
297297

298+
/** The caller does not have enough funds for value transfer. */
299+
EVMC_INSUFFICIENT_BALANCE = 17,
300+
298301
/** EVM implementation generic internal error. */
299302
EVMC_INTERNAL_ERROR = -1,
300303

tools/evmc/utils.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,9 @@ std::ostream& operator<<(std::ostream& os, evmc_status_code status_code)
102102
case EVMC_WASM_TRAP:
103103
s = "wasm trap";
104104
break;
105+
case EVMC_INSUFFICIENT_BALANCE:
106+
s = "insufficient balance";
107+
break;
105108
case EVMC_INTERNAL_ERROR:
106109
s = "internal error";
107110
break;

0 commit comments

Comments
 (0)