Replace Index for Nonce (#2740)

* replace Index for Nonce

* update lockfile for {"substrate", "polkadot"}

---------

Co-authored-by: parity-processbot <>
This commit is contained in:
Juan
2023-07-14 10:46:49 +02:00
committed by GitHub
parent 24d6e46ad0
commit 3513b7e019
44 changed files with 366 additions and 368 deletions
@@ -30,7 +30,7 @@ use pallet_bridge_messages::WeightInfoExt as _;
use sp_runtime::traits::SignedExtension;
/// Macro that ensures that the runtime configuration and chain primitives crate are sharing
/// the same types (index, block number, hash, hasher, account id and header).
/// the same types (nonce, block number, hash, hasher, account id and header).
#[macro_export]
macro_rules! assert_chain_types(
( runtime: $r:path, this_chain: $this:path ) => {
@@ -41,7 +41,7 @@ macro_rules! assert_chain_types(
use frame_system::{Config as SystemConfig, pallet_prelude::*};
use static_assertions::assert_type_eq_all;
assert_type_eq_all!(<$r as SystemConfig>::Index, bp_runtime::IndexOf<$this>);
assert_type_eq_all!(<$r as SystemConfig>::Nonce, bp_runtime::NonceOf<$this>);
assert_type_eq_all!(BlockNumberFor<$r>, bp_runtime::BlockNumberOf<$this>);
assert_type_eq_all!(<$r as SystemConfig>::Hash, bp_runtime::HashOf<$this>);
assert_type_eq_all!(<$r as SystemConfig>::Hashing, bp_runtime::HasherOf<$this>);
@@ -143,7 +143,7 @@ parameter_types! {
impl frame_system::Config for TestRuntime {
type RuntimeOrigin = RuntimeOrigin;
type Index = u64;
type Nonce = u64;
type RuntimeCall = RuntimeCall;
type Hash = ThisChainHash;
type Hashing = ThisChainHasher;
@@ -317,7 +317,7 @@ impl Chain for ThisUnderlyingChain {
type Hasher = ThisChainHasher;
type AccountId = ThisChainAccountId;
type Balance = ThisChainBalance;
type Index = u32;
type Nonce = u32;
type Signature = sp_runtime::MultiSignature;
fn max_extrinsic_size() -> u32 {
@@ -356,7 +356,7 @@ impl Chain for BridgedUnderlyingChain {
type Hasher = BridgedChainHasher;
type AccountId = BridgedChainAccountId;
type Balance = BridgedChainBalance;
type Index = u32;
type Nonce = u32;
type Signature = sp_runtime::MultiSignature;
fn max_extrinsic_size() -> u32 {
@@ -381,7 +381,7 @@ impl Chain for BridgedUnderlyingParachain {
type Hasher = BridgedChainHasher;
type AccountId = BridgedChainAccountId;
type Balance = BridgedChainBalance;
type Index = u32;
type Nonce = u32;
type Signature = sp_runtime::MultiSignature;
fn max_extrinsic_size() -> u32 {