Update EIP-8141: statically disallow approval scope on atomic-batch frames (#12109)
* Update EIP-8141: atomic-batch unroll rolls back the approval context
* Update EIP-8141: statically disallow approval scope on atomic-batch frames
Replace the atomic-batch approval-context rollback with a static
constraint: approval scope flags must be zero on every frame of an
atomic batch, including its terminating frame. Since APPROVE requires
its scope in frame.flags, the approval context cannot change inside a
batch, so unrolling never involves the nonce increment or max_cost
collection, and validity does not depend on the batch outcome.
The frame-revert rule is kept: an inner call from the resolved target
can APPROVE and the enclosing frame can still revert, so the approval
context must be discarded with that frame's state changes.
Tie the payer refund to the final value of payer, since a discarded
approval means more than one resolved_target may have called APPROVE.
* Trim the atomic-batch constraint comment
* 8141: clean up some more
* 8141: nit
* 8141: revert text about payer refund
---------
Co-authored-by: Marc Harvey-Hill <10379486+Marchhill@users.noreply.github.com>
Co-authored-by: lightclient <lightclient@protonmail.com>
GitHub Diff