Skip to content

"Production-ize" smoddit storage slot parser #696

@karlfloersch

Description

@karlfloersch

Is your feature request related to a problem? Please describe.
Smoddit contains logic which parses the storage layout of Solidity contracts and then sets the approprate storage slots for contract testing. This exact workflow is followed in the chugsplash deployment process because we must calculate and set storage slots of Solidity contracts for each deployment. This ticket is to take the smoddit logic & improve the test coverage to ensure that for simple cases storage slots are set correctly.

Describe the solution you'd like
Create a script which given a storage layout & some initial values, computes the exact storage slots to put the values in and then generates an object with all of the set storage slots and their values.

This script does not need to work for all storage types. However, the following should be supported:

  • Basic types like address bytes20 bytes32 uint64, etc
  • [optional?] Mappings between basic (static?) types like mapping(address->uint64)

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions