optimism
optimism copied to clipboard
feature: add support to initialize genesis contracts by function call
Currently the genesis contracts can only be initialized by manually specifying the state variables here.
It becomes hard if the state variable to initialize is a mapping or there're multiple inherits involved, it's boring to manually gather all the state variables modified .
In general, it's more feasible to allow initializing the contracts by function call instead, which is more flexible.
We will shortly be rewriting the L2 genesis generation in solidity to decouple releases of the predeploys from releases of op-node. You are correct that our storage setting library doesn't support mappings right now, its possible to add but we didn't need it so we didn't implement it at the time