mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-09 20:11:09 +00:00
sp-std removal from substrate/primitives (#3274)
This PR removes sp-std crate from substrate/primitives sub-directories. For now crates that have `pub use` of sp-std or export macros that would necessitate users of the macros to `extern crate alloc` have been excluded from this PR. There should be no breaking changes in this PR. --------- Co-authored-by: Koute <koute@users.noreply.github.com>
This commit is contained in:
@@ -20,14 +20,17 @@
|
||||
//! A crate which contains primitives that are useful for implementation that uses staking
|
||||
//! approaches in general. Definitions related to sessions, slashing, etc go here.
|
||||
|
||||
extern crate alloc;
|
||||
|
||||
use crate::currency_to_vote::CurrencyToVote;
|
||||
use alloc::{collections::btree_map::BTreeMap, vec, vec::Vec};
|
||||
use codec::{Decode, Encode, FullCodec, HasCompact, MaxEncodedLen};
|
||||
use core::ops::Sub;
|
||||
use scale_info::TypeInfo;
|
||||
use sp_runtime::{
|
||||
traits::{AtLeast32BitUnsigned, Zero},
|
||||
DispatchError, DispatchResult, RuntimeDebug, Saturating,
|
||||
};
|
||||
use sp_std::{collections::btree_map::BTreeMap, ops::Sub, vec, vec::Vec};
|
||||
|
||||
pub mod offence;
|
||||
|
||||
@@ -172,7 +175,7 @@ pub trait StakingInterface {
|
||||
+ Saturating;
|
||||
|
||||
/// AccountId type used by the staking system.
|
||||
type AccountId: Clone + sp_std::fmt::Debug;
|
||||
type AccountId: Clone + core::fmt::Debug;
|
||||
|
||||
/// Means of converting Currency to VoteWeight.
|
||||
type CurrencyToVote: CurrencyToVote<Self::Balance>;
|
||||
|
||||
@@ -18,10 +18,10 @@
|
||||
//! Common traits and types that are useful for describing offences for usage in environments
|
||||
//! that use staking.
|
||||
|
||||
use alloc::vec::Vec;
|
||||
use codec::{Decode, Encode};
|
||||
use sp_core::Get;
|
||||
use sp_runtime::{transaction_validity::TransactionValidityError, DispatchError, Perbill};
|
||||
use sp_std::vec::Vec;
|
||||
|
||||
use crate::SessionIndex;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user