-
Notifications
You must be signed in to change notification settings - Fork 377
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cancun support (v0.x) #303
base: v0.x
Are you sure you want to change the base?
Cancun support (v0.x) #303
Conversation
* feat: support transient storage opcodes (EIP-1153) * feat: support memory copying instruction (EIP-5656) * feat: Support cancun selfdestruct changes (EIP-6780) --------- Co-authored-by: Agusrodri <[email protected]> Co-authored-by: Ahmad Kaouk <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We have been using these changes in moonbeam for a few months already.
Most of these changes have been merged to master, the only missing one is #281 (EIP-6780: SELFDESTRUCT only in same transaction) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some small grumbles, but otherwise LGTM.
self.state.set_deleted(address); | ||
if self.config.has_eip_6780 && !self.state.created(address) { | ||
if address != target { | ||
self.state.transfer(Transfer { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can move this statement out of if
as it appears on both sides.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We have an inner if
statment (if address != target {
) in one of the sides. I don't think we can move it out without making it complicated.
Adds 2 new opcodes (
TLOAD
andTSTORE
) for manipulating state that behaves almost identically to storage but is discarded after every transaction.Adds a new opcode (
MCOPY
) for copying memory. Implementing this change will be important in ensuring that the same solidity/vyper contract compiles down to the same bytecode.´Changes the behaviour of the self destruct opcode.