Rewrite Inherent data (#1488)

* Implement new inherent data

* Fixes compilation on wasm

* Fixes after rebase

* Switch back to generate inherent stuff by macro

* Update after rebase

* Apply suggestions from code review

Co-Authored-By: bkchr <bkchr@users.noreply.github.com>

* Fix compilation after rebase

* Address grumbles

* Remove `InherentDataProviders` from `Client`

* Update wasm files after rebase

* Address grumbles

* Fixes compilation after latest merge

* Last fix
This commit is contained in:
Bastian Köcher
2019-01-22 17:52:08 +01:00
committed by GitHub
parent b14917e63f
commit 70b1af7b1e
55 changed files with 1513 additions and 661 deletions
+1 -2
View File
@@ -406,7 +406,7 @@ impl<V: 'static + Verifier<Block>, D> Peer<V, D> {
/// Add blocks to the peer -- edit the block before adding
pub fn generate_blocks<F>(&self, count: usize, origin: BlockOrigin, mut edit_block: F)
where F: FnMut(BlockBuilder<Block, (), PeersClient>) -> Block
where F: FnMut(BlockBuilder<Block, PeersClient>) -> Block
{
for _ in 0..count {
let builder = self.client.new_block().unwrap();
@@ -493,7 +493,6 @@ pub trait TestNetFactory: Sized {
fn from_config(config: &ProtocolConfig) -> Self;
fn make_verifier(&self, client: Arc<PeersClient>, config: &ProtocolConfig) -> Arc<Self::Verifier>;
/// Get reference to peer.
fn peer(&self, i: usize) -> &Peer<Self::Verifier, Self::PeerData>;
fn peers(&self) -> &Vec<Arc<Peer<Self::Verifier, Self::PeerData>>>;