Enum kimchi::circuits::expr::ConstantExprInner
source · pub enum ConstantExprInner<F, ChallengeTerm> {
Challenge(ChallengeTerm),
Constant(ConstantTerm<F>),
}
Variants§
Challenge(ChallengeTerm)
Constant(ConstantTerm<F>)
Trait Implementations§
source§impl<F: Clone, ChallengeTerm: Clone> Clone for ConstantExprInner<F, ChallengeTerm>
impl<F: Clone, ChallengeTerm: Clone> Clone for ConstantExprInner<F, ChallengeTerm>
source§fn clone(&self) -> ConstantExprInner<F, ChallengeTerm>
fn clone(&self) -> ConstantExprInner<F, ChallengeTerm>
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl<'a, F: PrimeField, ChallengeTerm> FormattedOutput for ConstantExprInner<F, ChallengeTerm>where
ChallengeTerm: AlphaChallengeTerm<'a>,
impl<'a, F: PrimeField, ChallengeTerm> FormattedOutput for ConstantExprInner<F, ChallengeTerm>where ChallengeTerm: AlphaChallengeTerm<'a>,
source§impl<'a, F, ChallengeTerm: AlphaChallengeTerm<'a>> From<ChallengeTerm> for ConstantExprInner<F, ChallengeTerm>
impl<'a, F, ChallengeTerm: AlphaChallengeTerm<'a>> From<ChallengeTerm> for ConstantExprInner<F, ChallengeTerm>
source§impl<F, ChallengeTerm> From<ConstantTerm<F>> for ConstantExprInner<F, ChallengeTerm>
impl<F, ChallengeTerm> From<ConstantTerm<F>> for ConstantExprInner<F, ChallengeTerm>
source§fn from(x: ConstantTerm<F>) -> Self
fn from(x: ConstantTerm<F>) -> Self
Converts to this type from the input type.
source§impl<'a, F: Clone, ChallengeTerm: AlphaChallengeTerm<'a>> Literal for ConstantExprInner<F, ChallengeTerm>
impl<'a, F: Clone, ChallengeTerm: AlphaChallengeTerm<'a>> Literal for ConstantExprInner<F, ChallengeTerm>
type F = F
fn literal(x: Self::F) -> Self
fn to_literal(self) -> Result<Self::F, Self>
fn to_literal_ref(&self) -> Option<&Self::F>
source§fn as_literal(&self, constants: &Constants<Self::F>) -> Self
fn as_literal(&self, constants: &Constants<Self::F>) -> Self
Obtains the representation of some constants as a literal.
This is useful before converting Kimchi expressions with constants
to folding compatible expressions.
source§impl<F: PartialEq, ChallengeTerm: PartialEq> PartialEq<ConstantExprInner<F, ChallengeTerm>> for ConstantExprInner<F, ChallengeTerm>
impl<F: PartialEq, ChallengeTerm: PartialEq> PartialEq<ConstantExprInner<F, ChallengeTerm>> for ConstantExprInner<F, ChallengeTerm>
source§fn eq(&self, other: &ConstantExprInner<F, ChallengeTerm>) -> bool
fn eq(&self, other: &ConstantExprInner<F, ChallengeTerm>) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.impl<F, ChallengeTerm> StructuralPartialEq for ConstantExprInner<F, ChallengeTerm>
Auto Trait Implementations§
impl<F, ChallengeTerm> RefUnwindSafe for ConstantExprInner<F, ChallengeTerm>where ChallengeTerm: RefUnwindSafe, F: RefUnwindSafe,
impl<F, ChallengeTerm> Send for ConstantExprInner<F, ChallengeTerm>where ChallengeTerm: Send, F: Send,
impl<F, ChallengeTerm> Sync for ConstantExprInner<F, ChallengeTerm>where ChallengeTerm: Sync, F: Sync,
impl<F, ChallengeTerm> Unpin for ConstantExprInner<F, ChallengeTerm>where ChallengeTerm: Unpin, F: Unpin,
impl<F, ChallengeTerm> UnwindSafe for ConstantExprInner<F, ChallengeTerm>where ChallengeTerm: 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