chore: helper caller_touch_and_change added#3032
Merged
Conversation
CodSpeed Performance ReportMerging #3032 will not alter performanceComparing Summary
|
mattsse
reviewed
Oct 1, 2025
Collaborator
mattsse
left a comment
There was a problem hiding this comment.
makes sense, one idea and doc nit
klkvr
reviewed
Oct 1, 2025
Comment on lines
-169
to
-173
| // Bump the nonce for calls. Nonce for CREATE will be bumped in `make_create_frame`. | ||
| if tx.kind().is_call() { | ||
| // Nonce is already checked | ||
| caller_account.info.nonce = caller_account.info.nonce.saturating_add(1); | ||
| } |
Collaborator
There was a problem hiding this comment.
wondering if we could bump call nonces in make_call_frame too? right now the flow is not very intuitive and moving it into caller_touch_and_change just makes it harder to reason about
Member
Author
There was a problem hiding this comment.
Caller nonce is not bumped for CALL/STATICCALL/etc, while the caller of CREATE/CREATE opcode is bumped. That is why nonce bump is here.
In future i would even like to add the value deduction here, but this requires changing more senstive code, so I am delaying it for later.
4356d99 to
5b968ff
Compare
Merged
theochap
pushed a commit
to ethereum-optimism/optimism
that referenced
this pull request
Jan 21, 2026
* chore: helper caller_touch_and_change added * move caller_touch_and_change to Account * rn artifact from merge * rename to caller_initial_modification
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Refactor account changed from
validate_against_state_and_deduct_callerinto one function. Split from PR #2991