mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-13 02:21:14 +00:00
Migrate network, primitives and rpc to the 2018 edition (#1710)
This commit is contained in:
committed by
Gav Wood
parent
3a4dda7beb
commit
e60be1ad12
@@ -18,11 +18,12 @@
|
||||
|
||||
pub use network_libp2p::{NonReservedPeerMode, NetworkConfiguration, Secret};
|
||||
|
||||
use chain::Client;
|
||||
use codec;
|
||||
use on_demand::OnDemandService;
|
||||
use bitflags::bitflags;
|
||||
use crate::chain::Client;
|
||||
use parity_codec;
|
||||
use crate::on_demand::OnDemandService;
|
||||
use runtime_primitives::traits::{Block as BlockT};
|
||||
use service::{ExHashT, TransactionPool};
|
||||
use crate::service::{ExHashT, TransactionPool};
|
||||
use std::sync::Arc;
|
||||
|
||||
/// Service initialization parameters.
|
||||
@@ -70,14 +71,14 @@ bitflags! {
|
||||
}
|
||||
}
|
||||
|
||||
impl codec::Encode for Roles {
|
||||
fn encode_to<T: codec::Output>(&self, dest: &mut T) {
|
||||
impl parity_codec::Encode for Roles {
|
||||
fn encode_to<T: parity_codec::Output>(&self, dest: &mut T) {
|
||||
dest.push_byte(self.bits())
|
||||
}
|
||||
}
|
||||
|
||||
impl codec::Decode for Roles {
|
||||
fn decode<I: codec::Input>(input: &mut I) -> Option<Self> {
|
||||
impl parity_codec::Decode for Roles {
|
||||
fn decode<I: parity_codec::Input>(input: &mut I) -> Option<Self> {
|
||||
Self::from_bits(input.read_byte()?)
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user