mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-04-27 12:48:00 +00:00
contracts: Improve contract address derivation (#12883)
* Add prefix to address derivation * Extend benchmark * Fix node test * ".git/.scripts/bench-bot.sh" pallet dev pallet_contracts * Adapt to new benchmark * Update dispatchable benchmarks * ".git/.scripts/bench-bot.sh" pallet dev pallet_contracts * Use benchmark results * Apply suggestions from code review Co-authored-by: Sasha Gryaznov <hi@agryaznov.com> * Don't use T::AdressGenerator directly * Rename constructor_args to input_data Co-authored-by: command-bot <> Co-authored-by: Sasha Gryaznov <hi@agryaznov.com>
This commit is contained in:
committed by
GitHub
parent
af15848be0
commit
4083b5358a
@@ -29,7 +29,6 @@ use frame_support::{
|
||||
DefaultNoBound, RuntimeDebugNoBound,
|
||||
};
|
||||
use pallet_contracts_primitives::StorageDeposit as Deposit;
|
||||
use sp_core::crypto::UncheckedFrom;
|
||||
use sp_runtime::{
|
||||
traits::{Saturating, Zero},
|
||||
FixedPointNumber, FixedU128,
|
||||
@@ -255,7 +254,6 @@ impl<T: Config> Default for Contribution<T> {
|
||||
impl<T, E, S> RawMeter<T, E, S>
|
||||
where
|
||||
T: Config,
|
||||
T::AccountId: UncheckedFrom<T::Hash> + AsRef<[u8]>,
|
||||
E: Ext<T>,
|
||||
S: State,
|
||||
{
|
||||
@@ -325,7 +323,6 @@ where
|
||||
impl<T, E> RawMeter<T, E, Root>
|
||||
where
|
||||
T: Config,
|
||||
T::AccountId: UncheckedFrom<T::Hash> + AsRef<[u8]>,
|
||||
E: Ext<T>,
|
||||
{
|
||||
/// Create new storage meter for the specified `origin` and `limit`.
|
||||
@@ -361,7 +358,6 @@ where
|
||||
impl<T, E> RawMeter<T, E, Nested>
|
||||
where
|
||||
T: Config,
|
||||
T::AccountId: UncheckedFrom<T::Hash> + AsRef<[u8]>,
|
||||
E: Ext<T>,
|
||||
{
|
||||
/// Try to charge the `diff` from the meter. Fails if this would exceed the original limit.
|
||||
@@ -441,11 +437,7 @@ where
|
||||
}
|
||||
}
|
||||
|
||||
impl<T> Ext<T> for ReservingExt
|
||||
where
|
||||
T: Config,
|
||||
T::AccountId: UncheckedFrom<T::Hash> + AsRef<[u8]>,
|
||||
{
|
||||
impl<T: Config> Ext<T> for ReservingExt {
|
||||
fn check_limit(
|
||||
origin: &T::AccountId,
|
||||
limit: Option<BalanceOf<T>>,
|
||||
|
||||
Reference in New Issue
Block a user