Skip to content

Commit f5410b7

Browse files
committed
Update EIP-8037: 5) CALL with value to selfdestructed account, no change (clarification)
1 parent a150714 commit f5410b7

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

EIPS/eip-8037.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -203,6 +203,12 @@ When an account is created and self-destructed in the same transaction ([EIP-678
203203

204204
This refund must be applied before `tx_gas_used_before_refund` is computed so the sender is not charged for state that was destroyed. Storage slots that were restored to zero during execution (0 to X to 0) already have a final value of 0 and are not counted, avoiding a double refund with the SSTORE restoration refund.
205205

206+
### CALL with value to the selfdestructed account in the same transaction
207+
208+
When an account is created and then selfdestructed in the same transaction ([EIP-6780](./eip-6780.md)), deletion is deferred to the end of the transaction. During the transaction the account is still present in the state with a nonce of 1 from the CREATE, and is therefore neither empty nor nonexistent. A subsequent `CALL` with value to that address does **not** trigger a new account creation and therefore does **not** charge `GAS_NEW_ACCOUNT` state gas.
209+
210+
The end of the transaction destruction still removes the account regardless of any value received after the SELFDESTRUCT, so no persisted state results from the CALL. Any value transferred is burned when the account is destroyed. Combined with the same transaction SELFDESTRUCT refund above, the net state gas across the CREATE, SELFDESTRUCT, and CALL with value lifecycle is zero, matching the zero persisted state.
211+
206212
#### [EIP-2780](./eip-2780.md) authorizations
207213

208214
For [EIP-7702](./eip-7702.md) authorizations, the intrinsic state gas assumes account creation for each authorization: `(112 + 23) × cost_per_state_byte` per authorization. When an authorization targets an existing account (no account creation needed), the `112 × cost_per_state_byte` portion is refunded to `state_gas_reservoir` and subtracted from `intrinsic_state_gas` during authorization processing, before state changes begin. The `intrinsic_state_gas` adjustment is required so that `tx_state_gas = intrinsic_state_gas + execution_state_gas_used` does not double count the refunded gas.

0 commit comments

Comments
 (0)