malone Profile picture
engineer building for @ethereum Irish 🇮🇪

Nov 11, 2022, 7 tweets

(1/6) Proxy contracts are used all the time in @solidity_lang for many different reasons.

In this post I explain the concept of ‘storage collisions’ and how to avoid them when it comes to proxy contracts.

May your storage be collision resistant from this day forth 💥 🧼 🧽

(2/6) Storage collisions suck.

They’ll cause all kinds of bugs in your application. 🐜

Many libraries like @OpenZeppelin handle a lot of the internal details for you; but understanding what’s going on under the hood is great to improve your @solidity_lang skills.

(3/6) I know there’s a lot to digest in this diagram but many of the concepts are topics that we’ve already covered.

For example:

Delegatecall ☎️

(4/6) and the fallback function 🕳

(5/6) In later posts I’ll dive into what I looks like to upgrade a @solidity_lang contract.

Yes, they’re immutable but there are clever ways of achieving upgradability which piggybacks on the architecture introduced above.

(6/6) As always, if you like this content follow me for more coming soon!

Share this Scrolly Tale with your friends.

A Scrolly Tale is a new way to read Twitter threads with a more visually immersive experience.
Discover more beautiful Scrolly Tales like this.

Keep scrolling