private void clearAccumulatedStateBesidesGasAndOutput(final MessageFrame frame) {
    ArrayList<Address> addresses =
        frame.getWorldUpdater().getTouchedAccounts().stream()
            .filter(AccountState::isEmpty)
            .map(Account::getAddress)
            .filter(forceDeleteAccountsWhenEmpty::contains)
            .collect(Collectors.toCollection(ArrayList::new));

    // Clear any pending changes.
    frame.getWorldUpdater().revert();

    // Force delete any requested accounts and commit the changes.
    ((Collection<Address>) addresses).forEach(h -> frame.getWorldUpdater().deleteAccount(h));
    frame.getWorldUpdater().commit();

    frame.clearLogs();
    frame.clearGasRefund();

    frame.rollback();
  }
Gets called when the message frame code executes successfully.

@param frame The message frame
@param operationTracer The tracer recording execution
evm/src/main/java/org/hyperledger/besu/evm/processor/AbstractMessageProcessor.java