Skip to content

is there a posible storage clash in smallProxy.sol that uses "delegateCall" between _IMPLEMENTATION_SLOT and value variables? #2310

Discussion options

You must be logged in to vote

@krakxn there is no "storage" collision because for the constant and immutable state variables "The compiler does not reserve a storage slot for these variables, and every occurrence is replaced by the respective value." so those values are saved in the contract's deployed code itself.

Patrick talk about this in the minute 12:10:15 of the 32 hours video and this detail is in the solidity docs in "contracts" section. Just a note: a non constant bytes state variable would have a storage slot in the EVM layout and then it could be participant in a storage collision.

Replies: 2 comments 2 replies

Comment options

You must be logged in to vote
1 reply
@albatros-github
Comment options

Comment options

You must be logged in to vote
1 reply
@krakxn
Comment options

Answer selected by albatros-github
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants