mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-13 09:21:05 +00:00
Add FixedPointOperand blanket implementation (#14634)
* bound `Balance` to `FixedPointOperand` * ".git/.scripts/commands/fmt/fmt.sh" * clean up code * Apply suggestions from code review Co-authored-by: Gavin Wood <gavin@parity.io> * wip * add blanket `FixedPointOperand` impl * update nis CurrencyBalance * remove CheckedNeg bound --------- Co-authored-by: command-bot <> Co-authored-by: Gavin Wood <gavin@parity.io>
This commit is contained in:
@@ -22,7 +22,7 @@ use frame_support::{
|
||||
pallet_prelude::*,
|
||||
traits::{fungible, tokens::ConversionToAssetBalance},
|
||||
};
|
||||
use sp_runtime::{traits::Convert, FixedPointNumber, FixedPointOperand, FixedU128};
|
||||
use sp_runtime::{traits::Convert, FixedPointNumber, FixedU128};
|
||||
|
||||
pub(super) type DepositBalanceOf<T, I = ()> =
|
||||
<<T as Config<I>>::Currency as Currency<<T as SystemConfig>::AccountId>>::Balance;
|
||||
@@ -293,8 +293,6 @@ where
|
||||
T: Config<I>,
|
||||
I: 'static,
|
||||
CON: Convert<BalanceOf<F, T>, AssetBalanceOf<T, I>>,
|
||||
BalanceOf<F, T>: FixedPointOperand + Zero,
|
||||
AssetBalanceOf<T, I>: FixedPointOperand + Zero,
|
||||
{
|
||||
type Error = ConversionError;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user