mirror of
https://github.com/hl-archive-node/nanoreth.git
synced 2025-12-06 10:59:55 +00:00
feat: add osaka hardfork (#11984)
This commit is contained in:
@ -617,6 +617,7 @@ impl From<Genesis> for ChainSpec {
|
||||
(EthereumHardfork::Shanghai.boxed(), genesis.config.shanghai_time),
|
||||
(EthereumHardfork::Cancun.boxed(), genesis.config.cancun_time),
|
||||
(EthereumHardfork::Prague.boxed(), genesis.config.prague_time),
|
||||
(EthereumHardfork::Osaka.boxed(), genesis.config.osaka_time),
|
||||
];
|
||||
|
||||
let mut time_hardforks = time_hardfork_opts
|
||||
@ -864,6 +865,13 @@ impl ChainSpecBuilder {
|
||||
self
|
||||
}
|
||||
|
||||
/// Enable Osaka at genesis.
|
||||
pub fn osaka_activated(mut self) -> Self {
|
||||
self = self.prague_activated();
|
||||
self.hardforks.insert(EthereumHardfork::Osaka, ForkCondition::Timestamp(0));
|
||||
self
|
||||
}
|
||||
|
||||
/// Build the resulting [`ChainSpec`].
|
||||
///
|
||||
/// # Panics
|
||||
|
||||
Reference in New Issue
Block a user