Struct boojum::gadgets::num::prime_field_like::NumExtAsFieldWrapper
source · pub struct NumExtAsFieldWrapper<F: SmallField, EXT: FieldExtension<2, BaseField = F>, CS: ConstraintSystem<F>> { /* private fields */ }
Implementations§
source§impl<F: SmallField, EXT: FieldExtension<2, BaseField = F>, CS: ConstraintSystem<F> + 'static> NumExtAsFieldWrapper<F, EXT, CS>
impl<F: SmallField, EXT: FieldExtension<2, BaseField = F>, CS: ConstraintSystem<F> + 'static> NumExtAsFieldWrapper<F, EXT, CS>
pub const fn from_coeffs_in_base(coeffs: [NumAsFieldWrapper<F, CS>; 2]) -> Self
pub fn from_num_coeffs_in_base(coeffs: [Num<F>; 2]) -> Self
pub const fn into_coeffs_in_base(self) -> [NumAsFieldWrapper<F, CS>; 2]
pub const fn into_num_coeffs_in_base(self) -> [Num<F>; 2]
pub fn mul_assign_by_base( &mut self, base: &NumAsFieldWrapper<F, CS>, cs: &mut CS, )
pub fn conditionally_select( cs: &mut CS, flag: Boolean<F>, a: &Self, b: &Self, ) -> Self
pub fn mul_by_base_and_accumulate_into( dst: &mut Self, base: &NumAsFieldWrapper<F, CS>, other: &Self, cs: &mut CS, )
Trait Implementations§
source§impl<F: SmallField, EXT: FieldExtension<2, BaseField = F>, CSO: ConstraintSystem<F> + 'static> CSAllocatable<F> for NumExtAsFieldWrapper<F, EXT, CSO>
impl<F: SmallField, EXT: FieldExtension<2, BaseField = F>, CSO: ConstraintSystem<F> + 'static> CSAllocatable<F> for NumExtAsFieldWrapper<F, EXT, CSO>
type Witness = ExtensionField<F, 2, EXT>
fn allocate<CS: ConstraintSystem<F>>( cs: &mut CS, witness: Self::Witness, ) -> Self
fn allocate_without_value<CS: ConstraintSystem<F>>(cs: &mut CS) -> Self
fn placeholder_witness() -> Self::Witness
fn allocate_constant<CS: ConstraintSystem<F>>( _cs: &mut CS, _witness: Self::Witness, ) -> Self
source§impl<F: SmallField, EXT: FieldExtension<2, BaseField = F>, CS: ConstraintSystem<F>> Clone for NumExtAsFieldWrapper<F, EXT, CS>
impl<F: SmallField, EXT: FieldExtension<2, BaseField = F>, CS: ConstraintSystem<F>> Clone for NumExtAsFieldWrapper<F, EXT, CS>
source§impl<F: SmallField, EXT: FieldExtension<2, BaseField = F>, CS: ConstraintSystem<F>> Debug for NumExtAsFieldWrapper<F, EXT, CS>
impl<F: SmallField, EXT: FieldExtension<2, BaseField = F>, CS: ConstraintSystem<F>> Debug for NumExtAsFieldWrapper<F, EXT, CS>
source§impl<F: SmallField, EXT: FieldExtension<2, BaseField = F>, CS: ConstraintSystem<F>> Display for NumExtAsFieldWrapper<F, EXT, CS>
impl<F: SmallField, EXT: FieldExtension<2, BaseField = F>, CS: ConstraintSystem<F>> Display for NumExtAsFieldWrapper<F, EXT, CS>
source§impl<F: SmallField, EXT: FieldExtension<2, BaseField = F>, CS: ConstraintSystem<F>> Hash for NumExtAsFieldWrapper<F, EXT, CS>
impl<F: SmallField, EXT: FieldExtension<2, BaseField = F>, CS: ConstraintSystem<F>> Hash for NumExtAsFieldWrapper<F, EXT, CS>
source§impl<F: SmallField, EXT: FieldExtension<2, BaseField = F>, CS> PrimeFieldLike for NumExtAsFieldWrapper<F, EXT, CS>where
CS: 'static + ConstraintSystem<F>,
impl<F: SmallField, EXT: FieldExtension<2, BaseField = F>, CS> PrimeFieldLike for NumExtAsFieldWrapper<F, EXT, CS>where
CS: 'static + ConstraintSystem<F>,
type Base = F
type Context = CS
fn zero(ctx: &mut Self::Context) -> Self
fn one(ctx: &mut Self::Context) -> Self
fn minus_one(ctx: &mut Self::Context) -> Self
fn add_assign(&mut self, other: &Self, ctx: &mut Self::Context) -> &mut Self
fn sub_assign(&mut self, other: &Self, ctx: &mut Self::Context) -> &mut Self
fn mul_assign(&mut self, other: &Self, ctx: &mut Self::Context) -> &mut Self
fn square(&mut self, ctx: &mut Self::Context) -> &mut Self
fn negate(&mut self, ctx: &mut Self::Context) -> &mut Self
fn double(&mut self, ctx: &mut Self::Context) -> &mut Self
fn inverse(&self, ctx: &mut Self::Context) -> Self
fn constant(value: Self::Base, ctx: &mut Self::Context) -> Self
fn mul_and_accumulate_into( acc: &mut Self, a: &Self, b: &Self, ctx: &mut Self::Context, )
fn pow_u64(&self, power: u64, ctx: &mut Self::Context) -> Self
fn small_pow(&mut self, pow: usize, ctx: &mut Self::Context)
source§impl<F: SmallField, EXT: FieldExtension<2, BaseField = F>, CSO: ConstraintSystem<F> + 'static> WitnessHookable<F> for NumExtAsFieldWrapper<F, EXT, CSO>
impl<F: SmallField, EXT: FieldExtension<2, BaseField = F>, CSO: ConstraintSystem<F> + 'static> WitnessHookable<F> for NumExtAsFieldWrapper<F, EXT, CSO>
fn witness_hook<CS: ConstraintSystem<F>>( &self, cs: &CS, ) -> Box<dyn FnOnce() -> Option<Self::Witness> + 'static>
impl<F: SmallField, EXT: FieldExtension<2, BaseField = F>, CS: ConstraintSystem<F>> Copy for NumExtAsFieldWrapper<F, EXT, CS>
Auto Trait Implementations§
impl<F, EXT, CS> Freeze for NumExtAsFieldWrapper<F, EXT, CS>
impl<F, EXT, CS> RefUnwindSafe for NumExtAsFieldWrapper<F, EXT, CS>where
EXT: RefUnwindSafe,
F: RefUnwindSafe,
impl<F, EXT, CS> Send for NumExtAsFieldWrapper<F, EXT, CS>
impl<F, EXT, CS> Sync for NumExtAsFieldWrapper<F, EXT, CS>
impl<F, EXT, CS> Unpin for NumExtAsFieldWrapper<F, EXT, CS>
impl<F, EXT, CS> UnwindSafe for NumExtAsFieldWrapper<F, EXT, CS>where
EXT: UnwindSafe,
F: UnwindSafe,
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)source§impl<T> IntoEither for T
impl<T> IntoEither for T
source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moresource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more