pub trait NumericSize:
Clone
+ Default
+ PartialOrd
+ Num
+ Zero
+ Bounded
+ AddAssign
+ 'static {
// Required methods
fn checked_add_value(
self,
other: Self,
) -> Result<Self, NumericArithmeticError>;
fn checked_mul_value(
self,
other: Self,
) -> Result<Self, NumericArithmeticError>;
}Expand description
Bound for objective value types (i64, f64, etc.)
Required Methods§
Sourcefn checked_add_value(self, other: Self) -> Result<Self, NumericArithmeticError>
fn checked_add_value(self, other: Self) -> Result<Self, NumericArithmeticError>
Add two values when the exact result remains representable and finite.
Sourcefn checked_mul_value(self, other: Self) -> Result<Self, NumericArithmeticError>
fn checked_mul_value(self, other: Self) -> Result<Self, NumericArithmeticError>
Multiply two values when the exact result remains representable and finite.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".