mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-04-27 20:57:59 +00:00
Better Parameterisation for Fee system (#3823)
* Better fee parameters * Fix build * Better runtime tests * Price to Weight ratio as type parameter (#3856) * Price to Weight ration as type parameter * Kian feedback * Some renames. * Fix executor tests * Getting Closer. * Phantom Data * Actually fix executor tests. * Fix tests. * Remove todo * Fix build
This commit is contained in:
@@ -21,7 +21,7 @@ use rstd::{cmp::Ordering, ops, prelude::*, cell::RefCell, convert::TryFrom};
|
||||
|
||||
// A sensible value for this would be half of the dword size of the host machine. Since the
|
||||
// runtime is compiled to 32bit webassembly, using 32 and 64 for single and double respectively
|
||||
// should yield the most performance. TODO #3745 we could benchmark this and verify.
|
||||
// should yield the most performance.
|
||||
/// Representation of a single limb.
|
||||
pub type Single = u32;
|
||||
/// Representation of two limbs.
|
||||
|
||||
@@ -48,6 +48,12 @@ impl Fixed64 {
|
||||
DIV
|
||||
}
|
||||
|
||||
/// Consume self and return the inner value.
|
||||
///
|
||||
/// This should only be used for testing.
|
||||
#[cfg(any(feature = "std", test))]
|
||||
pub fn into_inner(self) -> i64 { self.0 }
|
||||
|
||||
/// Raw constructor. Equal to `parts / 1_000_000_000`.
|
||||
pub fn from_parts(parts: i64) -> Self {
|
||||
Self(parts)
|
||||
|
||||
Reference in New Issue
Block a user