Skip to content

Latest commit

 

History

History
21 lines (20 loc) · 870 Bytes

Storage Layout & Inheritance.md

File metadata and controls

21 lines (20 loc) · 870 Bytes

Storage Layout & Inheritance: For contracts that use inheritance, the ordering of state variables is determined by the C3-linearized order of contracts starting with the most base-ward contract.

If allowed by the above rules, state variables from different contracts do share the same storage slot.


Slide Screenshot

118.jpg


Slide Text

  • Contract Inheritance -> Storage Layout
  • Base(s) -> Derived State Vars Layout
  • C3-Linearized Order
  • Moster Base-ward -> Derived
  • State Vars -> Diff Contracts
  • Rules -> Some Storage Slot

References


Tags

InheritanceState Variables