From 3dc2b1273192fb9bd15f4f816247d86b0a59f611 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pawe=C5=82=20Bylica?= Date: Thu, 15 Oct 2020 23:16:48 +0200 Subject: [PATCH] baseline: Implement SELFDESTRUCT --- lib/evmone/baseline.cpp | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/lib/evmone/baseline.cpp b/lib/evmone/baseline.cpp index ba61bee121..7ba555a15b 100644 --- a/lib/evmone/baseline.cpp +++ b/lib/evmone/baseline.cpp @@ -707,6 +707,13 @@ evmc_result baseline_execute(evmc_vm* /*vm*/, const evmc_host_interface* host, case OP_INVALID: state->status = EVMC_INVALID_INSTRUCTION; goto exit; + case OP_SELFDESTRUCT: + state->status = selfdestruct(*state); + goto exit; + default: + // TODO: Should not happen. + state->status = EVMC_INTERNAL_ERROR; + goto exit; } ++pc;