I want to use
delegatecall to make my contracts upgradeable.
Is it true that variable layout may break if I change the
solc version and therefore I should use the same Solidity version for all future versions of my contract?
Ethereum Stack Exchange is a question and answer site for users of Ethereum, the decentralized application platform and smart contract enabled blockchain. It only takes a minute to sign up.Sign up to join this community
From Solidity the documentation:
The layout of state variables in storage is considered to be part of the external interface of Solidity due to the fact that storage pointers can be passed to libraries. This means that any change to the rules outlined in this section is considered a breaking change of the language and due to its critical nature should be considered very carefully before being executed.
Since that kind of changes might break a lot of already deployed contracts my guess is that they will not change the layout unless there's a very very good reason to do so.