mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-05-31 06:21:02 +00:00
ChainWithGrandpa in primitives (#1885)
* ChainWithGrandpa in primitives * clippy ++ spelling * fix benchmarks comppilation
This commit is contained in:
committed by
Bastian Köcher
parent
914213d0af
commit
c6c39be967
@@ -73,11 +73,6 @@ pub trait RelayChain: Chain {
|
||||
const PARACHAINS_FINALITY_PALLET_NAME: &'static str;
|
||||
}
|
||||
|
||||
/// Substrate-based parachain from minimal relay-client point of view.
|
||||
pub trait Parachain: Chain + ParachainBase {}
|
||||
|
||||
impl<T> Parachain for T where T: UnderlyingChainProvider + Chain + ParachainBase {}
|
||||
|
||||
/// Substrate-based chain that is using direct GRANDPA finality from minimal relay-client point of
|
||||
/// view.
|
||||
///
|
||||
@@ -92,6 +87,20 @@ pub trait ChainWithGrandpa: Chain {
|
||||
const WITH_CHAIN_GRANDPA_PALLET_NAME: &'static str;
|
||||
}
|
||||
|
||||
impl<T> ChainWithGrandpa for T
|
||||
where
|
||||
T: Chain + UnderlyingChainProvider,
|
||||
T::Chain: bp_header_chain::ChainWithGrandpa,
|
||||
{
|
||||
const WITH_CHAIN_GRANDPA_PALLET_NAME: &'static str =
|
||||
<T::Chain as bp_header_chain::ChainWithGrandpa>::WITH_CHAIN_GRANDPA_PALLET_NAME;
|
||||
}
|
||||
|
||||
/// Substrate-based parachain from minimal relay-client point of view.
|
||||
pub trait Parachain: Chain + ParachainBase {}
|
||||
|
||||
impl<T> Parachain for T where T: UnderlyingChainProvider + Chain + ParachainBase {}
|
||||
|
||||
/// Substrate-based chain with messaging support from minimal relay-client point of view.
|
||||
pub trait ChainWithMessages: Chain {
|
||||
/// Name of the bridge messages pallet (used in `construct_runtime` macro call) that is deployed
|
||||
|
||||
Reference in New Issue
Block a user