Add untested minimum viable block processing

This commit is contained in:
Paul Hauner
2018-10-29 20:29:15 +01:00
parent e27c4106e9
commit 46da9b670f
21 changed files with 891 additions and 465 deletions

View File

@@ -1,8 +1,5 @@
use super::Hash256;
use super::{
AttestationRecord,
SpecialRecord,
};
use super::{AttestationRecord, SpecialRecord};
#[derive(Debug, PartialEq)]
pub struct ActiveState {
@@ -11,3 +8,10 @@ pub struct ActiveState {
pub recent_block_hashes: Vec<Hash256>,
pub randao_mix: Hash256,
}
impl ActiveState {
// TODO: implement this.
pub fn canonical_root(&self) -> Hash256 {
Hash256::zero()
}
}

View File

@@ -1,9 +1,8 @@
use super::validator_record::ValidatorRecord;
use super::crosslink_record::CrosslinkRecord;
use super::shard_and_committee::ShardAndCommittee;
use super::validator_record::ValidatorRecord;
use super::Hash256;
#[derive(Debug, PartialEq)]
pub struct CrystallizedState {
pub validator_set_change_slot: u64,
@@ -20,3 +19,10 @@ pub struct CrystallizedState {
pub post_fork_version: u32,
pub fork_slot_number: u32,
}
impl CrystallizedState {
// TODO: implement this.
pub fn canonical_root(&self) -> Hash256 {
Hash256::zero()
}
}