pub struct IncomingInstanceVar<CM: CommitmentDefGadget> {
pub cm_w: CM::CommitmentVar,
pub x: Vec<CM::ScalarVar>,
}Expand description
IncomingInstanceVar defines Nova’s incoming instance variable.
Fields§
§cm_w: CM::CommitmentVarIncomingInstanceVar::cm_w is the witness commitment.
x: Vec<CM::ScalarVar>IncomingInstanceVar::x is the vector of public inputs (to the
circuit).
Trait Implementations§
Source§impl<CM: CommitmentDefGadget> AbsorbableVar<<CM as CommitmentDefGadget>::ConstraintField> for IncomingInstanceVar<CM>
impl<CM: CommitmentDefGadget> AbsorbableVar<<CM as CommitmentDefGadget>::ConstraintField> for IncomingInstanceVar<CM>
Source§fn absorb_into(
&self,
dest: &mut Vec<FpVar<CM::ConstraintField>>,
) -> Result<(), SynthesisError>
fn absorb_into( &self, dest: &mut Vec<FpVar<CM::ConstraintField>>, ) -> Result<(), SynthesisError>
AbsorbableVar::absorb_into absorbs self into the given
destination vector of field element variables. Read moreSource§impl<CM: CommitmentDefGadget> AllocVar<IncomingInstance<<CM as CommitmentDefGadget>::Widget>, <CM as CommitmentDefGadget>::ConstraintField> for IncomingInstanceVar<CM>
impl<CM: CommitmentDefGadget> AllocVar<IncomingInstance<<CM as CommitmentDefGadget>::Widget>, <CM as CommitmentDefGadget>::ConstraintField> for IncomingInstanceVar<CM>
Source§fn new_variable<T: Borrow<IncomingInstance<CM::Widget>>>(
cs: impl Into<Namespace<CM::ConstraintField>>,
f: impl FnOnce() -> Result<T, SynthesisError>,
mode: AllocationMode,
) -> Result<Self, SynthesisError>
fn new_variable<T: Borrow<IncomingInstance<CM::Widget>>>( cs: impl Into<Namespace<CM::ConstraintField>>, f: impl FnOnce() -> Result<T, SynthesisError>, mode: AllocationMode, ) -> Result<Self, SynthesisError>
Allocates a new variable of type
Self in the ConstraintSystem cs.
The mode of allocation is decided by mode.Source§fn new_constant(
cs: impl Into<Namespace<F>>,
t: impl Borrow<V>,
) -> Result<Self, SynthesisError>
fn new_constant( cs: impl Into<Namespace<F>>, t: impl Borrow<V>, ) -> Result<Self, SynthesisError>
Source§fn new_input<T>(
cs: impl Into<Namespace<F>>,
f: impl FnOnce() -> Result<T, SynthesisError>,
) -> Result<Self, SynthesisError>where
T: Borrow<V>,
fn new_input<T>(
cs: impl Into<Namespace<F>>,
f: impl FnOnce() -> Result<T, SynthesisError>,
) -> Result<Self, SynthesisError>where
T: Borrow<V>,
Allocates a new public input of type
Self in the ConstraintSystem
cs.Source§fn new_witness<T>(
cs: impl Into<Namespace<F>>,
f: impl FnOnce() -> Result<T, SynthesisError>,
) -> Result<Self, SynthesisError>where
T: Borrow<V>,
fn new_witness<T>(
cs: impl Into<Namespace<F>>,
f: impl FnOnce() -> Result<T, SynthesisError>,
) -> Result<Self, SynthesisError>where
T: Borrow<V>,
Allocates a new private witness of type
Self in the ConstraintSystem
cs.Source§fn new_variable_with_inferred_mode<T>(
cs: impl Into<Namespace<F>>,
f: impl FnOnce() -> Result<T, SynthesisError>,
) -> Result<Self, SynthesisError>where
T: Borrow<V>,
fn new_variable_with_inferred_mode<T>(
cs: impl Into<Namespace<F>>,
f: impl FnOnce() -> Result<T, SynthesisError>,
) -> Result<Self, SynthesisError>where
T: Borrow<V>,
Allocates a new constant or private witness of type
Self in the
ConstraintSystem cs with the allocation mode inferred from cs.
A constant is allocated if cs is None, and a private witness is
allocated otherwise. Read moreSource§impl<CM: Clone + CommitmentDefGadget> Clone for IncomingInstanceVar<CM>
impl<CM: Clone + CommitmentDefGadget> Clone for IncomingInstanceVar<CM>
Source§fn clone(&self) -> IncomingInstanceVar<CM>
fn clone(&self) -> IncomingInstanceVar<CM>
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl<CM: CommitmentDefGadget> CondSelectGadget<<CM as CommitmentDefGadget>::ConstraintField> for IncomingInstanceVar<CM>
impl<CM: CommitmentDefGadget> CondSelectGadget<<CM as CommitmentDefGadget>::ConstraintField> for IncomingInstanceVar<CM>
Source§fn conditionally_select(
cond: &Boolean<CM::ConstraintField>,
true_value: &Self,
false_value: &Self,
) -> Result<Self, SynthesisError>
fn conditionally_select( cond: &Boolean<CM::ConstraintField>, true_value: &Self, false_value: &Self, ) -> Result<Self, SynthesisError>
Source§fn conditionally_select_power_of_two_vector(
position: &[Boolean<ConstraintF>],
values: &[Self],
) -> Result<Self, SynthesisError>
fn conditionally_select_power_of_two_vector( position: &[Boolean<ConstraintF>], values: &[Self], ) -> Result<Self, SynthesisError>
Returns an element of
values whose index in represented by position.
position is an array of boolean that represents an unsigned integer in
big endian order. Read moreSource§impl<CM: Debug + CommitmentDefGadget> Debug for IncomingInstanceVar<CM>
impl<CM: Debug + CommitmentDefGadget> Debug for IncomingInstanceVar<CM>
Source§impl<CM: CommitmentDefGadget> FoldingInstanceVar<CM> for IncomingInstanceVar<CM>
impl<CM: CommitmentDefGadget> FoldingInstanceVar<CM> for IncomingInstanceVar<CM>
Source§fn commitments(&self) -> Vec<&CM::CommitmentVar>
fn commitments(&self) -> Vec<&CM::CommitmentVar>
FoldingInstanceVar::commitments returns the commitments contained in
the instance variable.Source§fn public_inputs(&self) -> &Vec<CM::ScalarVar>
fn public_inputs(&self) -> &Vec<CM::ScalarVar>
FoldingInstanceVar::public_inputs returns the reference to the
public inputs contained in the instance variable.Source§fn new_witness_with_public_inputs(
cs: impl Into<Namespace<CM::ConstraintField>>,
u: &Self::Value,
x: Vec<CM::ScalarVar>,
) -> Result<Self, SynthesisError>
fn new_witness_with_public_inputs( cs: impl Into<Namespace<CM::ConstraintField>>, u: &Self::Value, x: Vec<CM::ScalarVar>, ) -> Result<Self, SynthesisError>
FoldingInstanceVar::new_witness_with_public_inputs allocates a
folding instance in the circuit as a witness variable, with the given
pre-allocated public inputs.Source§impl<CM: CommitmentDefGadget> GR1CSVar<<CM as CommitmentDefGadget>::ConstraintField> for IncomingInstanceVar<CM>
impl<CM: CommitmentDefGadget> GR1CSVar<<CM as CommitmentDefGadget>::ConstraintField> for IncomingInstanceVar<CM>
Source§type Value = IncomingInstance<<CM as CommitmentDefGadget>::Widget>
type Value = IncomingInstance<<CM as CommitmentDefGadget>::Widget>
The type of the “native” value that
Self represents in the constraint
system.Source§fn cs(&self) -> ConstraintSystemRef<CM::ConstraintField>
fn cs(&self) -> ConstraintSystemRef<CM::ConstraintField>
Returns the underlying
ConstraintSystemRef. Read moreSource§fn value(&self) -> Result<Self::Value, SynthesisError>
fn value(&self) -> Result<Self::Value, SynthesisError>
Returns the value that is assigned to
self in the underlying
ConstraintSystem.Source§fn is_constant(&self) -> bool
fn is_constant(&self) -> bool
Returns
true if self is a circuit-generation-time constant.Source§impl<CM: PartialEq + CommitmentDefGadget> PartialEq for IncomingInstanceVar<CM>
impl<CM: PartialEq + CommitmentDefGadget> PartialEq for IncomingInstanceVar<CM>
impl<CM: PartialEq + CommitmentDefGadget> StructuralPartialEq for IncomingInstanceVar<CM>
Auto Trait Implementations§
impl<CM> Freeze for IncomingInstanceVar<CM>
impl<CM> RefUnwindSafe for IncomingInstanceVar<CM>where
<CM as CommitmentDefGadget>::CommitmentVar: RefUnwindSafe,
<CM as CommitmentDefGadget>::ScalarVar: RefUnwindSafe,
impl<CM> Send for IncomingInstanceVar<CM>where
<CM as CommitmentDefGadget>::CommitmentVar: Send,
<CM as CommitmentDefGadget>::ScalarVar: Send,
impl<CM> Sync for IncomingInstanceVar<CM>where
<CM as CommitmentDefGadget>::CommitmentVar: Sync,
<CM as CommitmentDefGadget>::ScalarVar: Sync,
impl<CM> Unpin for IncomingInstanceVar<CM>where
<CM as CommitmentDefGadget>::CommitmentVar: Unpin,
<CM as CommitmentDefGadget>::ScalarVar: Unpin,
impl<CM> UnsafeUnpin for IncomingInstanceVar<CM>
impl<CM> UnwindSafe for IncomingInstanceVar<CM>where
<CM as CommitmentDefGadget>::CommitmentVar: UnwindSafe,
<CM as CommitmentDefGadget>::ScalarVar: 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§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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