Trait snarkvm_circuit::environment::prelude::SubWrapped
pub trait SubWrapped<Rhs = Self>where
Rhs: ?Sized,{
type Output;
// Required method
fn sub_wrapped(&self, rhs: &Rhs) -> Self::Output;
}
Expand description
Binary operator for subtracting two values, wrapping the difference if an underflow occurs.
Required Associated Types§
type Output
Required Methods§
fn sub_wrapped(&self, rhs: &Rhs) -> Self::Output
Trait Implementations§
§impl<E, I> Metrics<dyn SubWrapped<Integer<E, I>, Output = Integer<E, I>>> for Integer<E, I>where
E: Environment,
I: IntegerType,
impl<E, I> Metrics<dyn SubWrapped<Integer<E, I>, Output = Integer<E, I>>> for Integer<E, I>where E: Environment, I: IntegerType,
§impl<E, I> OutputMode<dyn SubWrapped<Integer<E, I>, Output = Integer<E, I>>> for Integer<E, I>where
E: Environment,
I: IntegerType,
impl<E, I> OutputMode<dyn SubWrapped<Integer<E, I>, Output = Integer<E, I>>> for Integer<E, I>where E: Environment, I: IntegerType,
type Case = (Mode, Mode)
§fn output_mode(
case: &<Integer<E, I> as OutputMode<dyn SubWrapped<Integer<E, I>, Output = Integer<E, I>>>>::Case
) -> Mode
fn output_mode( case: &<Integer<E, I> as OutputMode<dyn SubWrapped<Integer<E, I>, Output = Integer<E, I>>>>::Case ) -> Mode
Returns the mode of the output.
Implementations on Foreign Types§
§impl<E, I> SubWrapped<Integer<E, I>> for Integer<E, I>where
E: Environment,
I: IntegerType,
impl<E, I> SubWrapped<Integer<E, I>> for Integer<E, I>where E: Environment, I: IntegerType,
§fn sub_wrapped(
&self,
other: &Integer<E, I>
) -> <Integer<E, I> as SubWrapped<Integer<E, I>>>::Output
fn sub_wrapped( &self, other: &Integer<E, I> ) -> <Integer<E, I> as SubWrapped<Integer<E, I>>>::Output
Returns the difference
of self
and other
.