Trait slot_range_helper::Add

1.0.0 · source ·
pub trait Add<Rhs = Self> {
    type Output;

    fn add(self, rhs: Rhs) -> Self::Output;
}
Expand description

The addition operator +.

Note that Rhs is Self by default, but this is not mandatory. For example, std::time::SystemTime implements Add<Duration>, which permits operations of the form SystemTime = SystemTime + Duration.

Examples

Addable points

use std::ops::Add;

#[derive(Debug, Copy, Clone, PartialEq)]
struct Point {
    x: i32,
    y: i32,
}

impl Add for Point {
    type Output = Self;

    fn add(self, other: Self) -> Self {
        Self {
            x: self.x + other.x,
            y: self.y + other.y,
        }
    }
}

assert_eq!(Point { x: 1, y: 0 } + Point { x: 2, y: 3 },
           Point { x: 3, y: 3 });

Implementing Add with generics

Here is an example of the same Point struct implementing the Add trait using generics.

use std::ops::Add;

#[derive(Debug, Copy, Clone, PartialEq)]
struct Point<T> {
    x: T,
    y: T,
}

// Notice that the implementation uses the associated type `Output`.
impl<T: Add<Output = T>> Add for Point<T> {
    type Output = Self;

    fn add(self, other: Self) -> Self::Output {
        Self {
            x: self.x + other.x,
            y: self.y + other.y,
        }
    }
}

assert_eq!(Point { x: 1, y: 0 } + Point { x: 2, y: 3 },
           Point { x: 3, y: 3 });

Required Associated Types§

The resulting type after applying the + operator.

Required Methods§

Performs the + operation.

Example
assert_eq!(12 + 1, 13);

Implementors§

Implements the + operator for concatenating two strings.

This consumes the String on the left-hand side and re-uses its buffer (growing it if necessary). This is done to avoid allocating a new String and copying the entire contents on every operation, which would lead to O(n^2) running time when building an n-byte string by repeated concatenation.

The string on the right-hand side is only borrowed; its contents are copied into the returned String.

Examples

Concatenating two Strings takes the first by value and borrows the second:

let a = String::from("hello");
let b = String::from(" world");
let c = a + &b;
// `a` is moved and can no longer be used here.

If you want to keep using the first String, you can clone it and append to the clone instead:

let a = String::from("hello");
let b = String::from(" world");
let c = a.clone() + &b;
// `a` is still valid here.

Concatenating &str slices can be done by converting the first to a String:

let a = "hello";
let b = " world";
let c = a.to_string() + b;

An addition of Duration to NaiveDate discards the fractional days, rounding to the closest integral number of days towards Duration::zero().

Panics on underflow or overflow. Use NaiveDate::checked_add_signed to detect that.

Example

use chrono::{Duration, NaiveDate};

let from_ymd = NaiveDate::from_ymd;

assert_eq!(from_ymd(2014, 1, 1) + Duration::zero(),             from_ymd(2014, 1, 1));
assert_eq!(from_ymd(2014, 1, 1) + Duration::seconds(86399),     from_ymd(2014, 1, 1));
assert_eq!(from_ymd(2014, 1, 1) + Duration::seconds(-86399),    from_ymd(2014, 1, 1));
assert_eq!(from_ymd(2014, 1, 1) + Duration::days(1),            from_ymd(2014, 1, 2));
assert_eq!(from_ymd(2014, 1, 1) + Duration::days(-1),           from_ymd(2013, 12, 31));
assert_eq!(from_ymd(2014, 1, 1) + Duration::days(364),          from_ymd(2014, 12, 31));
assert_eq!(from_ymd(2014, 1, 1) + Duration::days(365*4 + 1),    from_ymd(2018, 1, 1));
assert_eq!(from_ymd(2014, 1, 1) + Duration::days(365*400 + 97), from_ymd(2414, 1, 1));

An addition of Duration to NaiveDateTime yields another NaiveDateTime.

As a part of Chrono’s leap second handling, the addition assumes that there is no leap second ever, except when the NaiveDateTime itself represents a leap second in which case the assumption becomes that there is exactly a single leap second ever.

Panics on underflow or overflow. Use NaiveDateTime::checked_add_signed to detect that.

Example

use chrono::{Duration, NaiveDate};

let from_ymd = NaiveDate::from_ymd;

let d = from_ymd(2016, 7, 8);
let hms = |h, m, s| d.and_hms(h, m, s);
assert_eq!(hms(3, 5, 7) + Duration::zero(),             hms(3, 5, 7));
assert_eq!(hms(3, 5, 7) + Duration::seconds(1),         hms(3, 5, 8));
assert_eq!(hms(3, 5, 7) + Duration::seconds(-1),        hms(3, 5, 6));
assert_eq!(hms(3, 5, 7) + Duration::seconds(3600 + 60), hms(4, 6, 7));
assert_eq!(hms(3, 5, 7) + Duration::seconds(86_400),
           from_ymd(2016, 7, 9).and_hms(3, 5, 7));
assert_eq!(hms(3, 5, 7) + Duration::days(365),
           from_ymd(2017, 7, 8).and_hms(3, 5, 7));

let hmsm = |h, m, s, milli| d.and_hms_milli(h, m, s, milli);
assert_eq!(hmsm(3, 5, 7, 980) + Duration::milliseconds(450), hmsm(3, 5, 8, 430));

Leap seconds are handled, but the addition assumes that it is the only leap second happened.

let leap = hmsm(3, 5, 59, 1_300);
assert_eq!(leap + Duration::zero(),             hmsm(3, 5, 59, 1_300));
assert_eq!(leap + Duration::milliseconds(-500), hmsm(3, 5, 59, 800));
assert_eq!(leap + Duration::milliseconds(500),  hmsm(3, 5, 59, 1_800));
assert_eq!(leap + Duration::milliseconds(800),  hmsm(3, 6, 0, 100));
assert_eq!(leap + Duration::seconds(10),        hmsm(3, 6, 9, 300));
assert_eq!(leap + Duration::seconds(-10),       hmsm(3, 5, 50, 300));
assert_eq!(leap + Duration::days(1),
           from_ymd(2016, 7, 9).and_hms_milli(3, 5, 59, 300));

An addition of Duration to NaiveTime wraps around and never overflows or underflows. In particular the addition ignores integral number of days.

As a part of Chrono’s leap second handling, the addition assumes that there is no leap second ever, except when the NaiveTime itself represents a leap second in which case the assumption becomes that there is exactly a single leap second ever.

Example

use chrono::{Duration, NaiveTime};

let from_hmsm = NaiveTime::from_hms_milli;

assert_eq!(from_hmsm(3, 5, 7, 0) + Duration::zero(),                  from_hmsm(3, 5, 7, 0));
assert_eq!(from_hmsm(3, 5, 7, 0) + Duration::seconds(1),              from_hmsm(3, 5, 8, 0));
assert_eq!(from_hmsm(3, 5, 7, 0) + Duration::seconds(-1),             from_hmsm(3, 5, 6, 0));
assert_eq!(from_hmsm(3, 5, 7, 0) + Duration::seconds(60 + 4),         from_hmsm(3, 6, 11, 0));
assert_eq!(from_hmsm(3, 5, 7, 0) + Duration::seconds(7*60*60 - 6*60), from_hmsm(9, 59, 7, 0));
assert_eq!(from_hmsm(3, 5, 7, 0) + Duration::milliseconds(80),        from_hmsm(3, 5, 7, 80));
assert_eq!(from_hmsm(3, 5, 7, 950) + Duration::milliseconds(280),     from_hmsm(3, 5, 8, 230));
assert_eq!(from_hmsm(3, 5, 7, 950) + Duration::milliseconds(-980),    from_hmsm(3, 5, 6, 970));

The addition wraps around.

assert_eq!(from_hmsm(3, 5, 7, 0) + Duration::seconds(22*60*60), from_hmsm(1, 5, 7, 0));
assert_eq!(from_hmsm(3, 5, 7, 0) + Duration::seconds(-8*60*60), from_hmsm(19, 5, 7, 0));
assert_eq!(from_hmsm(3, 5, 7, 0) + Duration::days(800),         from_hmsm(3, 5, 7, 0));

Leap seconds are handled, but the addition assumes that it is the only leap second happened.

let leap = from_hmsm(3, 5, 59, 1_300);
assert_eq!(leap + Duration::zero(),             from_hmsm(3, 5, 59, 1_300));
assert_eq!(leap + Duration::milliseconds(-500), from_hmsm(3, 5, 59, 800));
assert_eq!(leap + Duration::milliseconds(500),  from_hmsm(3, 5, 59, 1_800));
assert_eq!(leap + Duration::milliseconds(800),  from_hmsm(3, 6, 0, 100));
assert_eq!(leap + Duration::seconds(10),        from_hmsm(3, 6, 9, 300));
assert_eq!(leap + Duration::seconds(-10),       from_hmsm(3, 5, 50, 300));
assert_eq!(leap + Duration::days(1),            from_hmsm(3, 5, 59, 300));

UTerm + B0 = UTerm

UTerm + B1 = UInt<UTerm, B1>

Z0 + I = I

UInt<U, B0> + B1 = UInt<U + B1>

UInt<U, B1> + B1 = UInt<U + B1, B0>

NInt + Z0 = NInt

PInt + Z0 = PInt

UTerm + U = U

U + B0 = U

UInt<U, B> + UTerm = UInt<U, B>

N(Ul) + N(Ur) = N(Ul + Ur)

P(Ul) + N(Ur): We resolve this with our PrivateAdd

N(Ul) + P(Ur): We resolve this with our PrivateAdd

P(Ul) + P(Ur) = P(Ul + Ur)

UInt<Ul, B0> + UInt<Ur, B0> = UInt<Ul + Ur, B0>

UInt<Ul, B1> + UInt<Ur, B0> = UInt<Ul + Ur, B1>

UInt<Ul, B0> + UInt<Ur, B1> = UInt<Ul + Ur, B1>

UInt<Ul, B1> + UInt<Ur, B1> = UInt<(Ul + Ur) + B1, B0>

impl Add<Duration> for Instant

impl Add<&Wrapping<Limb>> for &Wrapping<Limb>

impl Add<&Checked<Limb>> for Checked<Limb>

impl Add<Checked<Limb>> for &Checked<Limb>

impl Add<&Checked<Limb>> for &Checked<Limb>

impl<const LIMBS: usize> Add<Wrapping<UInt<LIMBS>>> for Wrapping<UInt<LIMBS>>

impl<const LIMBS: usize> Add<&Wrapping<UInt<LIMBS>>> for Wrapping<UInt<LIMBS>>

impl<const LIMBS: usize> Add<Wrapping<UInt<LIMBS>>> for &Wrapping<UInt<LIMBS>>

impl<const LIMBS: usize> Add<&Wrapping<UInt<LIMBS>>> for &Wrapping<UInt<LIMBS>>

impl<const LIMBS: usize> Add<Checked<UInt<LIMBS>>> for Checked<UInt<LIMBS>>

impl<const LIMBS: usize> Add<&Checked<UInt<LIMBS>>> for Checked<UInt<LIMBS>>

impl<const LIMBS: usize> Add<Checked<UInt<LIMBS>>> for &Checked<UInt<LIMBS>>

impl<const LIMBS: usize> Add<&Checked<UInt<LIMBS>>> for &Checked<UInt<LIMBS>>

impl Add<Length> for Length

impl Add<u8> for Length

impl Add<u16> for Length

impl Add<u32> for Length

impl Add<usize> for Length

impl Add<Length> for Result<Length>

impl<C> Add<ScalarCore<C>> for ScalarCore<C>where
    C: Curve,

impl<C> Add<&ScalarCore<C>> for ScalarCore<C>where
    C: Curve,

impl<Frac> Add<FixedU8<Frac>> for FixedU8<Frac>

impl<Frac> Add<FixedU8<Frac>> for &FixedU8<Frac>

impl<Frac> Add<&FixedU8<Frac>> for FixedU8<Frac>

impl<Frac> Add<&FixedU8<Frac>> for &FixedU8<Frac>

impl<Frac> Add<FixedU16<Frac>> for FixedU16<Frac>

impl<Frac> Add<FixedU16<Frac>> for &FixedU16<Frac>

impl<Frac> Add<&FixedU16<Frac>> for FixedU16<Frac>

impl<Frac> Add<&FixedU16<Frac>> for &FixedU16<Frac>

impl<Frac> Add<FixedU32<Frac>> for FixedU32<Frac>

impl<Frac> Add<FixedU32<Frac>> for &FixedU32<Frac>

impl<Frac> Add<&FixedU32<Frac>> for FixedU32<Frac>

impl<Frac> Add<&FixedU32<Frac>> for &FixedU32<Frac>

impl<Frac> Add<FixedU64<Frac>> for FixedU64<Frac>

impl<Frac> Add<FixedU64<Frac>> for &FixedU64<Frac>

impl<Frac> Add<&FixedU64<Frac>> for FixedU64<Frac>

impl<Frac> Add<&FixedU64<Frac>> for &FixedU64<Frac>

impl<Frac> Add<FixedU128<Frac>> for FixedU128<Frac>

impl<Frac> Add<FixedU128<Frac>> for &FixedU128<Frac>

impl<Frac> Add<&FixedU128<Frac>> for FixedU128<Frac>

impl<Frac> Add<&FixedU128<Frac>> for &FixedU128<Frac>

impl<Frac> Add<FixedI8<Frac>> for FixedI8<Frac>

impl<Frac> Add<FixedI8<Frac>> for &FixedI8<Frac>

impl<Frac> Add<&FixedI8<Frac>> for FixedI8<Frac>

impl<Frac> Add<&FixedI8<Frac>> for &FixedI8<Frac>

impl<Frac> Add<FixedI16<Frac>> for FixedI16<Frac>

impl<Frac> Add<FixedI16<Frac>> for &FixedI16<Frac>

impl<Frac> Add<&FixedI16<Frac>> for FixedI16<Frac>

impl<Frac> Add<&FixedI16<Frac>> for &FixedI16<Frac>

impl<Frac> Add<FixedI32<Frac>> for FixedI32<Frac>

impl<Frac> Add<FixedI32<Frac>> for &FixedI32<Frac>

impl<Frac> Add<&FixedI32<Frac>> for FixedI32<Frac>

impl<Frac> Add<&FixedI32<Frac>> for &FixedI32<Frac>

impl<Frac> Add<FixedI64<Frac>> for FixedI64<Frac>

impl<Frac> Add<FixedI64<Frac>> for &FixedI64<Frac>

impl<Frac> Add<&FixedI64<Frac>> for FixedI64<Frac>

impl<Frac> Add<&FixedI64<Frac>> for &FixedI64<Frac>

impl<Frac> Add<FixedI128<Frac>> for FixedI128<Frac>

impl<Frac> Add<FixedI128<Frac>> for &FixedI128<Frac>

impl<Frac> Add<&FixedI128<Frac>> for FixedI128<Frac>

impl<Frac> Add<&FixedI128<Frac>> for &FixedI128<Frac>

impl<F: Fixed> Add<Unwrapped<F>> for Unwrapped<F>

impl<F: Fixed> Add<Unwrapped<F>> for &Unwrapped<F>

impl<F: Fixed> Add<&Unwrapped<F>> for Unwrapped<F>

impl<F: Fixed> Add<&Unwrapped<F>> for &Unwrapped<F>

impl<F: Fixed> Add<Wrapping<F>> for Wrapping<F>

impl<F: Fixed> Add<Wrapping<F>> for &Wrapping<F>

impl<F: Fixed> Add<&Wrapping<F>> for Wrapping<F>

impl<F: Fixed> Add<&Wrapping<F>> for &Wrapping<F>

impl Add<Weight> for Weight

impl Add<bf16> for bf16

impl Add<&bf16> for bf16

impl Add<&bf16> for &bf16

impl Add<bf16> for &bf16

impl Add<f16> for f16

impl Add<&f16> for f16

impl Add<&f16> for &f16

impl Add<f16> for &f16

impl<Balance: CheckedAdd + CheckedSub + PartialOrd + Default> Add<BalanceUpdate<Balance>> for BalanceUpdate<Balance>

impl<Balance: Into<<FixedU128 as FixedPointNumber>::Inner> + CheckedAdd + CheckedSub + Copy + Default> Add<Balance> for BalanceUpdate<Balance>

impl Add<&BigInt> for &BigInt

impl<'a> Add<BigInt> for &'a BigInt

impl Add<&BigInt> for BigInt

impl Add<BigInt> for BigInt

impl Add<&Number> for &Number

impl<'a> Add<Number> for &'a Number

impl Add<&Number> for Number

impl Add<Number> for Number

impl Add<Scalar> for Scalar

impl Add<&Scalar> for &Scalar

impl Add<Scalar> for &Scalar

impl Add<&Scalar> for Scalar

impl Add<u64> for CircuitId

impl Add<usize> for Dynamic

impl<'b, T, R1, C1, R2, C2, SA, SB> Add<&'b Matrix<T, R2, C2, SB>> for Matrix<T, R1, C1, SA>where
    R1: Dim,
    C1: Dim,
    R2: Dim,
    C2: Dim,
    T: Scalar + ClosedAdd,
    SA: Storage<T, R1, C1>,
    SB: Storage<T, R2, C2>,
    DefaultAllocator: SameShapeAllocator<T, R1, C1, R2, C2>,
    ShapeConstraint: SameNumberOfRows<R1, R2> + SameNumberOfColumns<C1, C2>,

impl<'a, T, R1, C1, R2, C2, SA, SB> Add<Matrix<T, R2, C2, SB>> for &'a Matrix<T, R1, C1, SA>where
    R1: Dim,
    C1: Dim,
    R2: Dim,
    C2: Dim,
    T: Scalar + ClosedAdd,
    SA: Storage<T, R1, C1>,
    SB: Storage<T, R2, C2>,
    DefaultAllocator: SameShapeAllocator<T, R2, C2, R1, C1>,
    ShapeConstraint: SameNumberOfRows<R2, R1> + SameNumberOfColumns<C2, C1>,

impl<T, R1, C1, R2, C2, SA, SB> Add<Matrix<T, R2, C2, SB>> for Matrix<T, R1, C1, SA>where
    R1: Dim,
    C1: Dim,
    R2: Dim,
    C2: Dim,
    T: Scalar + ClosedAdd,
    SA: Storage<T, R1, C1>,
    SB: Storage<T, R2, C2>,
    DefaultAllocator: SameShapeAllocator<T, R1, C1, R2, C2>,
    ShapeConstraint: SameNumberOfRows<R1, R2> + SameNumberOfColumns<C1, C2>,

impl<'a, 'b, T, R1, C1, R2, C2, SA, SB> Add<&'b Matrix<T, R2, C2, SB>> for &'a Matrix<T, R1, C1, SA>where
    R1: Dim,
    C1: Dim,
    R2: Dim,
    C2: Dim,
    T: Scalar + ClosedAdd,
    SA: Storage<T, R1, C1>,
    SB: Storage<T, R2, C2>,
    DefaultAllocator: SameShapeAllocator<T, R1, C1, R2, C2>,
    ShapeConstraint: SameNumberOfRows<R1, R2> + SameNumberOfColumns<C1, C2>,

impl<'a, 'b, T, D2, SB, const D1: usize> Add<&'b Matrix<T, D2, Const<1>, SB>> for &'a Point<T, D1>where
    T: Scalar + ClosedAdd,
    ShapeConstraint: SameNumberOfRows<Const<D1>, D2, Representative = Const<D1>> + SameNumberOfColumns<U1, U1, Representative = U1>,
    D2: Dim,
    SB: Storage<T, D2>,

impl<'a, T, D2, SB, const D1: usize> Add<Matrix<T, D2, Const<1>, SB>> for &'a Point<T, D1>where
    T: Scalar + ClosedAdd,
    ShapeConstraint: SameNumberOfRows<Const<D1>, D2, Representative = Const<D1>> + SameNumberOfColumns<U1, U1, Representative = U1>,
    D2: Dim,
    SB: Storage<T, D2>,

impl<'b, T, D2, SB, const D1: usize> Add<&'b Matrix<T, D2, Const<1>, SB>> for Point<T, D1>where
    T: Scalar + ClosedAdd,
    ShapeConstraint: SameNumberOfRows<Const<D1>, D2, Representative = Const<D1>> + SameNumberOfColumns<U1, U1, Representative = U1>,
    D2: Dim,
    SB: Storage<T, D2>,

impl<T, D2, SB, const D1: usize> Add<Matrix<T, D2, Const<1>, SB>> for Point<T, D1>where
    T: Scalar + ClosedAdd,
    ShapeConstraint: SameNumberOfRows<Const<D1>, D2, Representative = Const<D1>> + SameNumberOfColumns<U1, U1, Representative = U1>,
    D2: Dim,
    SB: Storage<T, D2>,

impl<'a, 'b, T: SimdRealField> Add<&'b Quaternion<T>> for &'a Quaternion<T>where
    T::Element: SimdRealField,

impl<'a, T: SimdRealField> Add<Quaternion<T>> for &'a Quaternion<T>where
    T::Element: SimdRealField,

impl<'b, T: SimdRealField> Add<&'b Quaternion<T>> for Quaternion<T>where
    T::Element: SimdRealField,

impl<T: SimdRealField> Add<Quaternion<T>> for Quaternion<T>where
    T::Element: SimdRealField,

impl<'a, 'b, T: SimdRealField> Add<&'b DualQuaternion<T>> for &'a DualQuaternion<T>where
    T::Element: SimdRealField,

impl<'a, T: SimdRealField> Add<DualQuaternion<T>> for &'a DualQuaternion<T>where
    T::Element: SimdRealField,

impl<'b, T: SimdRealField> Add<&'b DualQuaternion<T>> for DualQuaternion<T>where
    T::Element: SimdRealField,

impl<T: SimdRealField> Add<DualQuaternion<T>> for DualQuaternion<T>where
    T::Element: SimdRealField,

impl Add<TimeVal> for TimeVal

impl<'a, 'b, T: Clone + Num> Add<&'b Complex<T>> for &'a Complex<T>

impl<'a, T: Clone + Num> Add<Complex<T>> for &'a Complex<T>

impl<'a, T: Clone + Num> Add<&'a Complex<T>> for Complex<T>

impl<T: Clone + Num> Add<Complex<T>> for Complex<T>

impl<T: Clone + Num> Add<T> for Complex<T>

impl<'a, T: Clone + Num> Add<&'a T> for Complex<T>

impl<'a, T: Clone + Num> Add<T> for &'a Complex<T>

impl<'a, 'b, T: Clone + Num> Add<&'a T> for &'b Complex<T>

impl<'a> Add<&'a Complex<usize>> for usize

impl<'a> Add<Complex<usize>> for &'a usize

impl<'a, 'b> Add<&'a Complex<usize>> for &'b usize

impl<'a> Add<&'a Complex<u8>> for u8

impl<'a> Add<Complex<u8>> for &'a u8

impl<'a, 'b> Add<&'a Complex<u8>> for &'b u8

impl<'a> Add<&'a Complex<u16>> for u16

impl<'a> Add<Complex<u16>> for &'a u16

impl<'a, 'b> Add<&'a Complex<u16>> for &'b u16

impl<'a> Add<&'a Complex<u32>> for u32

impl<'a> Add<Complex<u32>> for &'a u32

impl<'a, 'b> Add<&'a Complex<u32>> for &'b u32

impl<'a> Add<&'a Complex<u64>> for u64

impl<'a> Add<Complex<u64>> for &'a u64

impl<'a, 'b> Add<&'a Complex<u64>> for &'b u64

impl<'a> Add<&'a Complex<u128>> for u128

impl<'a> Add<Complex<u128>> for &'a u128

impl<'a, 'b> Add<&'a Complex<u128>> for &'b u128

impl<'a> Add<&'a Complex<isize>> for isize

impl<'a> Add<Complex<isize>> for &'a isize

impl<'a, 'b> Add<&'a Complex<isize>> for &'b isize

impl<'a> Add<&'a Complex<i8>> for i8

impl<'a> Add<Complex<i8>> for &'a i8

impl<'a, 'b> Add<&'a Complex<i8>> for &'b i8

impl<'a> Add<&'a Complex<i16>> for i16

impl<'a> Add<Complex<i16>> for &'a i16

impl<'a, 'b> Add<&'a Complex<i16>> for &'b i16

impl<'a> Add<&'a Complex<i32>> for i32

impl<'a> Add<Complex<i32>> for &'a i32

impl<'a, 'b> Add<&'a Complex<i32>> for &'b i32

impl<'a> Add<&'a Complex<i64>> for i64

impl<'a> Add<Complex<i64>> for &'a i64

impl<'a, 'b> Add<&'a Complex<i64>> for &'b i64

impl<'a> Add<&'a Complex<i128>> for i128

impl<'a> Add<Complex<i128>> for &'a i128

impl<'a, 'b> Add<&'a Complex<i128>> for &'b i128

impl<'a> Add<&'a Complex<f32>> for f32

impl<'a> Add<Complex<f32>> for &'a f32

impl<'a, 'b> Add<&'a Complex<f32>> for &'b f32

impl<'a> Add<&'a Complex<f64>> for f64

impl<'a> Add<Complex<f64>> for &'a f64

impl<'a, 'b> Add<&'a Complex<f64>> for &'b f64

impl Add<Complex<usize>> for usize

impl Add<Complex<u8>> for u8

impl Add<Complex<u16>> for u16

impl Add<Complex<u32>> for u32

impl Add<Complex<u64>> for u64

impl Add<Complex<u128>> for u128

impl Add<Complex<isize>> for isize

impl Add<Complex<i8>> for i8

impl Add<Complex<i16>> for i16

impl Add<Complex<i32>> for i32

impl Add<Complex<i64>> for i64

impl Add<Complex<i128>> for i128

impl Add<Complex<f32>> for f32

impl Add<Complex<f64>> for f64

impl<T: Float> Add<OrderedFloat<T>> for OrderedFloat<T>

impl<T: Float> Add<NotNan<T>> for NotNan<T>

impl<T: Float> Add<T> for NotNan<T>

impl Add<&PriceInfo> for &PriceInfo

impl Add<u32> for Id

impl Add<AutoSimd<[f32; 2]>> for AutoSimd<[f32; 2]>

impl Add<AutoSimd<[f32; 4]>> for AutoSimd<[f32; 4]>

impl Add<AutoSimd<[f32; 8]>> for AutoSimd<[f32; 8]>

impl Add<AutoSimd<[f32; 16]>> for AutoSimd<[f32; 16]>

impl Add<AutoSimd<[f64; 2]>> for AutoSimd<[f64; 2]>

impl Add<AutoSimd<[f64; 4]>> for AutoSimd<[f64; 4]>

impl Add<AutoSimd<[f64; 8]>> for AutoSimd<[f64; 8]>

impl Add<AutoSimd<[i128; 1]>> for AutoSimd<[i128; 1]>

impl Add<AutoSimd<[i128; 2]>> for AutoSimd<[i128; 2]>

impl Add<AutoSimd<[i128; 4]>> for AutoSimd<[i128; 4]>

impl Add<AutoSimd<[i16; 2]>> for AutoSimd<[i16; 2]>

impl Add<AutoSimd<[i16; 4]>> for AutoSimd<[i16; 4]>

impl Add<AutoSimd<[i16; 8]>> for AutoSimd<[i16; 8]>

impl Add<AutoSimd<[i16; 16]>> for AutoSimd<[i16; 16]>

impl Add<AutoSimd<[i16; 32]>> for AutoSimd<[i16; 32]>

impl Add<AutoSimd<[i32; 2]>> for AutoSimd<[i32; 2]>

impl Add<AutoSimd<[i32; 4]>> for AutoSimd<[i32; 4]>

impl Add<AutoSimd<[i32; 8]>> for AutoSimd<[i32; 8]>

impl Add<AutoSimd<[i32; 16]>> for AutoSimd<[i32; 16]>

impl Add<AutoSimd<[i64; 2]>> for AutoSimd<[i64; 2]>

impl Add<AutoSimd<[i64; 4]>> for AutoSimd<[i64; 4]>

impl Add<AutoSimd<[i64; 8]>> for AutoSimd<[i64; 8]>

impl Add<AutoSimd<[i8; 2]>> for AutoSimd<[i8; 2]>

impl Add<AutoSimd<[i8; 4]>> for AutoSimd<[i8; 4]>

impl Add<AutoSimd<[i8; 8]>> for AutoSimd<[i8; 8]>

impl Add<AutoSimd<[i8; 16]>> for AutoSimd<[i8; 16]>

impl Add<AutoSimd<[i8; 32]>> for AutoSimd<[i8; 32]>

impl Add<AutoSimd<[isize; 2]>> for AutoSimd<[isize; 2]>

impl Add<AutoSimd<[isize; 4]>> for AutoSimd<[isize; 4]>

impl Add<AutoSimd<[isize; 8]>> for AutoSimd<[isize; 8]>

impl Add<AutoSimd<[u128; 1]>> for AutoSimd<[u128; 1]>

impl Add<AutoSimd<[u128; 2]>> for AutoSimd<[u128; 2]>

impl Add<AutoSimd<[u128; 4]>> for AutoSimd<[u128; 4]>

impl Add<AutoSimd<[u16; 2]>> for AutoSimd<[u16; 2]>

impl Add<AutoSimd<[u16; 4]>> for AutoSimd<[u16; 4]>

impl Add<AutoSimd<[u16; 8]>> for AutoSimd<[u16; 8]>

impl Add<AutoSimd<[u16; 16]>> for AutoSimd<[u16; 16]>

impl Add<AutoSimd<[u16; 32]>> for AutoSimd<[u16; 32]>

impl Add<AutoSimd<[u32; 2]>> for AutoSimd<[u32; 2]>

impl Add<AutoSimd<[u32; 4]>> for AutoSimd<[u32; 4]>

impl Add<AutoSimd<[u32; 8]>> for AutoSimd<[u32; 8]>

impl Add<AutoSimd<[u32; 16]>> for AutoSimd<[u32; 16]>

impl Add<AutoSimd<[u64; 2]>> for AutoSimd<[u64; 2]>

impl Add<AutoSimd<[u64; 4]>> for AutoSimd<[u64; 4]>

impl Add<AutoSimd<[u64; 8]>> for AutoSimd<[u64; 8]>

impl Add<AutoSimd<[u8; 2]>> for AutoSimd<[u8; 2]>

impl Add<AutoSimd<[u8; 4]>> for AutoSimd<[u8; 4]>

impl Add<AutoSimd<[u8; 8]>> for AutoSimd<[u8; 8]>

impl Add<AutoSimd<[u8; 16]>> for AutoSimd<[u8; 16]>

impl Add<AutoSimd<[u8; 32]>> for AutoSimd<[u8; 32]>

impl Add<AutoSimd<[usize; 2]>> for AutoSimd<[usize; 2]>

impl Add<AutoSimd<[usize; 4]>> for AutoSimd<[usize; 4]>

impl Add<AutoSimd<[usize; 8]>> for AutoSimd<[usize; 8]>

impl Add<Slot> for Slot

impl Add<u64> for Slot

impl Add<u64> for Timestamp

impl Add<Duration> for Instant

impl Add<&JsValue> for &JsValue

impl<'a> Add<JsValue> for &'a JsValue

impl Add<&JsValue> for JsValue

impl Add<JsValue> for JsValue