Safe Haskell | None |
---|---|
Language | Haskell2010 |
Synopsis
- data family BlockConfig blk
- byronEpochSlots :: BlockConfig ByronBlock -> EpochSlots
- byronGenesisHash :: BlockConfig ByronBlock -> GenesisHash
- byronProtocolMagic :: BlockConfig ByronBlock -> ProtocolMagic
- byronProtocolMagicId :: BlockConfig ByronBlock -> ProtocolMagicId
- data family CodecConfig blk
- mkByronCodecConfig :: Config -> CodecConfig ByronBlock
- data family StorageConfig blk
- compactGenesisConfig :: Config -> Config
Block config
data family BlockConfig blk Source #
Static configuration required to work with this type of blocks
Instances
Codec config
data family CodecConfig blk Source #
Static configuration required for serialisation and deserialisation of types pertaining to this type of block.
Data family instead of type family to get better type inference.
Instances
Storage config
data family StorageConfig blk Source #
Config needed for the
NodeInitStorage
class. Defined here to
avoid circular dependencies.
Instances
Compact genesis config
compactGenesisConfig :: Config -> Config Source #
Byron's genesis config contains the AVVM balances, of which there are +14k in mainnet's genesis config. These balances are only used to create the initial ledger state, there is no reason to keep them in memory afterwards.
This function empties the
gdAvvmDistr
field in the genesis config. As we
keep Byron's genesis config in memory (even in later eras), this can save us
a bit of memory.