[−][src]Struct leo_gadgets::signed_integer::int_impl::Int16
Fields
bits: Vec<Boolean>
value: Option<i16>
Implementations
impl Int16
[src]
Trait Implementations
impl<F: PrimeField> Add<F, Int16> for Int16
[src]
type ErrorType = SignedIntegerError
pub fn add<CS: ConstraintSystem<F>>(
&self,
mut cs: CS,
other: &Self
) -> Result<Self, Self::ErrorType>
[src]
&self,
mut cs: CS,
other: &Self
) -> Result<Self, Self::ErrorType>
impl<F: Field> AllocGadget<<Int16 as Int>::IntegerType, F> for Int16
[src]
pub fn alloc<Fn: FnOnce() -> Result<T, SynthesisError>, T: Borrow<<Int16 as Int>::IntegerType>, CS: ConstraintSystem<F>>(
mut cs: CS,
value_gen: Fn
) -> Result<Self, SynthesisError>
[src]
mut cs: CS,
value_gen: Fn
) -> Result<Self, SynthesisError>
pub fn alloc_input<Fn: FnOnce() -> Result<T, SynthesisError>, T: Borrow<<Int16 as Int>::IntegerType>, CS: ConstraintSystem<F>>(
mut cs: CS,
value_gen: Fn
) -> Result<Self, SynthesisError>
[src]
mut cs: CS,
value_gen: Fn
) -> Result<Self, SynthesisError>
pub fn alloc_checked<Fn, T, CS>(cs: CS, f: Fn) -> Result<Self, SynthesisError> where
CS: ConstraintSystem<F>,
T: Borrow<V>,
Fn: FnOnce() -> Result<T, SynthesisError>,
[src]
CS: ConstraintSystem<F>,
T: Borrow<V>,
Fn: FnOnce() -> Result<T, SynthesisError>,
pub fn alloc_input_checked<Fn, T, CS>(
cs: CS,
f: Fn
) -> Result<Self, SynthesisError> where
CS: ConstraintSystem<F>,
T: Borrow<V>,
Fn: FnOnce() -> Result<T, SynthesisError>,
[src]
cs: CS,
f: Fn
) -> Result<Self, SynthesisError> where
CS: ConstraintSystem<F>,
T: Borrow<V>,
Fn: FnOnce() -> Result<T, SynthesisError>,
impl Clone for Int16
[src]
impl<F: PrimeField> ComparatorGadget<F> for Int16
[src]
pub fn greater_than<CS: ConstraintSystem<F>>(
&self,
cs: CS,
other: &Self
) -> Result<Boolean, SynthesisError>
[src]
&self,
cs: CS,
other: &Self
) -> Result<Boolean, SynthesisError>
pub fn less_than_or_equal<CS: ConstraintSystem<F>>(
&self,
cs: CS,
other: &Self
) -> Result<Boolean, SynthesisError>
[src]
&self,
cs: CS,
other: &Self
) -> Result<Boolean, SynthesisError>
pub fn greater_than_or_equal<CS: ConstraintSystem<F>>(
&self,
cs: CS,
other: &Self
) -> Result<Boolean, SynthesisError>
[src]
&self,
cs: CS,
other: &Self
) -> Result<Boolean, SynthesisError>
impl<F: PrimeField> CondSelectGadget<F> for Int16
[src]
pub fn conditionally_select<CS: ConstraintSystem<F>>(
mut cs: CS,
cond: &Boolean,
first: &Self,
second: &Self
) -> Result<Self, SynthesisError>
[src]
mut cs: CS,
cond: &Boolean,
first: &Self,
second: &Self
) -> Result<Self, SynthesisError>
pub fn cost() -> usize
[src]
impl<F: PrimeField> ConditionalEqGadget<F> for Int16
[src]
pub fn conditional_enforce_equal<CS: ConstraintSystem<F>>(
&self,
mut cs: CS,
other: &Self,
condition: &Boolean
) -> Result<(), SynthesisError>
[src]
&self,
mut cs: CS,
other: &Self,
condition: &Boolean
) -> Result<(), SynthesisError>
pub fn cost() -> usize
[src]
impl Debug for Int16
[src]
impl<F: PrimeField> Div<F, Int16> for Int16
[src]
type ErrorType = SignedIntegerError
pub fn div<CS: ConstraintSystem<F>>(
&self,
mut cs: CS,
other: &Self
) -> Result<Self, Self::ErrorType>
[src]
&self,
mut cs: CS,
other: &Self
) -> Result<Self, Self::ErrorType>
impl Eq for Int16
[src]
impl<F: PrimeField> EvaluateEqGadget<F> for Int16
[src]
pub fn evaluate_equal<CS: ConstraintSystem<F>>(
&self,
mut cs: CS,
other: &Self
) -> Result<Boolean, SynthesisError>
[src]
&self,
mut cs: CS,
other: &Self
) -> Result<Boolean, SynthesisError>
impl<F: PrimeField> EvaluateLtGadget<F> for Int16
[src]
pub fn less_than<CS: ConstraintSystem<F>>(
&self,
mut cs: CS,
other: &Self
) -> Result<Boolean, SynthesisError>
[src]
&self,
mut cs: CS,
other: &Self
) -> Result<Boolean, SynthesisError>
impl Int for Int16
[src]
type IntegerType = i16
pub const SIZE: usize
[src]
pub fn one() -> Self
[src]
pub fn zero() -> Self
[src]
pub fn is_constant(&self) -> bool
[src]
pub fn result_is_constant(first: &Self, second: &Self) -> bool
[src]
impl<F: PrimeField> Mul<F, Int16> for Int16
[src]
Bitwise multiplication of two signed integer objects.
type ErrorType = SignedIntegerError
pub fn mul<CS: ConstraintSystem<F>>(
&self,
mut cs: CS,
other: &Self
) -> Result<Self, Self::ErrorType>
[src]
&self,
mut cs: CS,
other: &Self
) -> Result<Self, Self::ErrorType>
impl<F: PrimeField> Neg<F> for Int16
[src]
type ErrorType = SignedIntegerError
pub fn neg<CS: ConstraintSystem<F>>(
&self,
cs: CS
) -> Result<Self, Self::ErrorType>
[src]
&self,
cs: CS
) -> Result<Self, Self::ErrorType>
impl PartialEq<Int16> for Int16
[src]
pub fn eq(&self, other: &Self) -> bool
[src]
#[must_use]pub fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
impl PartialOrd<Int16> for Int16
[src]
pub fn partial_cmp(&self, other: &Self) -> Option<Ordering>
[src]
#[must_use]pub fn lt(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]pub fn le(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]pub fn gt(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]pub fn ge(&self, other: &Rhs) -> bool
1.0.0[src]
impl<F: PrimeField> Pow<F, Int16> for Int16
[src]
type ErrorType = SignedIntegerError
pub fn pow<CS: ConstraintSystem<F>>(
&self,
mut cs: CS,
other: &Self
) -> Result<Self, Self::ErrorType>
[src]
&self,
mut cs: CS,
other: &Self
) -> Result<Self, Self::ErrorType>
impl<F: Field + PrimeField> RippleCarryAdder<F, Int16> for Int16
[src]
pub fn add_bits<CS: ConstraintSystem<F>>(
&self,
cs: CS,
other: &Self
) -> Result<Vec<Boolean>, SynthesisError>
[src]
&self,
cs: CS,
other: &Self
) -> Result<Vec<Boolean>, SynthesisError>
impl<F: PrimeField> Sub<F, Int16> for Int16
[src]
type ErrorType = SignedIntegerError
pub fn sub<CS: ConstraintSystem<F>>(
&self,
mut cs: CS,
other: &Self
) -> Result<Self, Self::ErrorType>
[src]
&self,
mut cs: CS,
other: &Self
) -> Result<Self, Self::ErrorType>
Auto Trait Implementations
impl RefUnwindSafe for Int16
[src]
impl Send for Int16
[src]
impl Sync for Int16
[src]
impl Unpin for Int16
[src]
impl UnwindSafe for Int16
[src]
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<F, T> ConditionalOrEqualsGadget<F> for T where
F: Field,
T: ConditionalEqGadget<F> + CondSelectGadget<F>,
[src]
F: Field,
T: ConditionalEqGadget<F> + CondSelectGadget<F>,
pub fn conditional_enforce_equal_or<CS>(
cs: CS,
cond: &Boolean,
var: &T,
first: &T,
second: &T,
should_enforce: &Boolean
) -> Result<(), SynthesisError> where
CS: ConstraintSystem<F>,
[src]
cs: CS,
cond: &Boolean,
var: &T,
first: &T,
second: &T,
should_enforce: &Boolean
) -> Result<(), SynthesisError> where
CS: ConstraintSystem<F>,
pub fn cost() -> usize
[src]
impl<Q, K> Equivalent<K> for Q where
K: Borrow<Q> + ?Sized,
Q: Eq + ?Sized,
[src]
K: Borrow<Q> + ?Sized,
Q: Eq + ?Sized,
pub fn equivalent(&self, key: &K) -> bool
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<F, T> OrEqualsGadget<F> for T where
F: Field,
T: ConditionalOrEqualsGadget<F>,
[src]
F: Field,
T: ConditionalOrEqualsGadget<F>,
pub fn enforce_equal_or<CS>(
cs: CS,
cond: &Boolean,
var: &T,
first: &T,
second: &T
) -> Result<(), SynthesisError> where
CS: ConstraintSystem<F>,
[src]
cs: CS,
cond: &Boolean,
var: &T,
first: &T,
second: &T
) -> Result<(), SynthesisError> where
CS: ConstraintSystem<F>,
pub fn cost() -> usize
[src]
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
pub fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,