OverflowingAdd

Trait OverflowingAdd 

Source
pub trait OverflowingAdd: Sized {
    // Required method
    fn overflowing_add(self, rhs: Self) -> Result<Self, ExecutionError>;
}
Expand description

Overflowing addition, returning the result of addition or ArithmeticsError::AdditionOverflow.

Required Methods§

Source

fn overflowing_add(self, rhs: Self) -> Result<Self, ExecutionError>

Overflowing addition. Compute self + rhs, returns the result or error if overflowed.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementations on Foreign Types§

Source§

impl OverflowingAdd for i8

Source§

fn overflowing_add(self, rhs: Self) -> Result<Self, ExecutionError>

Source§

impl OverflowingAdd for i16

Source§

fn overflowing_add(self, rhs: Self) -> Result<Self, ExecutionError>

Source§

impl OverflowingAdd for i32

Source§

fn overflowing_add(self, rhs: Self) -> Result<Self, ExecutionError>

Source§

impl OverflowingAdd for i64

Source§

fn overflowing_add(self, rhs: Self) -> Result<Self, ExecutionError>

Source§

impl OverflowingAdd for u8

Source§

fn overflowing_add(self, rhs: Self) -> Result<Self, ExecutionError>

Source§

impl OverflowingAdd for u16

Source§

fn overflowing_add(self, rhs: Self) -> Result<Self, ExecutionError>

Source§

impl OverflowingAdd for u32

Source§

fn overflowing_add(self, rhs: Self) -> Result<Self, ExecutionError>

Source§

impl OverflowingAdd for u64

Source§

fn overflowing_add(self, rhs: Self) -> Result<Self, ExecutionError>

Source§

impl OverflowingAdd for U128

Source§

fn overflowing_add(self, rhs: Self) -> Result<Self, ExecutionError>

Source§

impl OverflowingAdd for U256

Source§

fn overflowing_add(self, rhs: Self) -> Result<Self, ExecutionError>

Source§

impl OverflowingAdd for U512

Source§

fn overflowing_add(self, rhs: Self) -> Result<Self, ExecutionError>

Implementors§