You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Given that 0x is intended to be upgraded via decentralized governance, we need to make it as simple as possible for higher level protocols built using the 0x smart contracts to migrate to new versions. Currently, any change in the Exchange contract's ABI would require major upgrades in any smart contracts that use it. With a completely static ABI, any smart contracts that use Exchange can upgrade by simply updating a pointer to the new Exchange address, rather deploying a brand new contract.
Motivation
A static ABI allows allows for much more backwards compatability, making it much easier to upgrade.
Implementation
Rather than making all of the Exchange methods take typed arguments, we can always pass in a dynamic byte array. This way, changes to the arguments will not actually change the contract's ABI.
Summary
Given that 0x is intended to be upgraded via decentralized governance, we need to make it as simple as possible for higher level protocols built using the 0x smart contracts to migrate to new versions. Currently, any change in the Exchange contract's ABI would require major upgrades in any smart contracts that use it. With a completely static ABI, any smart contracts that use Exchange can upgrade by simply updating a pointer to the new Exchange address, rather deploying a brand new contract.
Motivation
A static ABI allows allows for much more backwards compatability, making it much easier to upgrade.
Implementation
Rather than making all of the
Exchange
methods take typed arguments, we can always pass in a dynamic byte array. This way, changes to the arguments will not actually change the contract's ABI.An example of what
fillOrder
might look like:The text was updated successfully, but these errors were encountered: