Altair consensus changes and refactors (#2279)

## Proposed Changes

Implement the consensus changes necessary for the upcoming Altair hard fork.

## Additional Info

This is quite a heavy refactor, with pivotal types like the `BeaconState` and `BeaconBlock` changing from structs to enums. This ripples through the whole codebase with field accesses changing to methods, e.g. `state.slot` => `state.slot()`.


Co-authored-by: realbigsean <seananderson33@gmail.com>
This commit is contained in:
Michael Sproul
2021-07-09 06:15:32 +00:00
parent 89361573d4
commit b4689e20c6
271 changed files with 9652 additions and 8444 deletions

View File

@@ -44,13 +44,6 @@ impl Eth2Config {
spec: ChainSpec::minimal(),
}
}
pub fn v012_legacy() -> Self {
Self {
eth_spec_id: EthSpecId::V012Legacy,
spec: ChainSpec::v012_legacy(),
}
}
}
/// A directory that can be built by downloading files via HTTP.
@@ -112,16 +105,8 @@ macro_rules! define_net {
};
}
define_net!(altona, include_altona_file, "altona", true);
define_net!(medalla, include_medalla_file, "medalla", true);
define_net!(spadina, include_spadina_file, "spadina", true);
define_net!(pyrmont, include_pyrmont_file, "pyrmont", true);
define_net!(mainnet, include_mainnet_file, "mainnet", true);
define_net!(toledo, include_toledo_file, "toledo", true);
define_net!(prater, include_prater_file, "prater", true);