Skip to main content

RelationGadget

Trait RelationGadget 

Source
pub trait RelationGadget<WVar, UVar> {
    // Required method
    fn check_relation(&self, w: &WVar, u: &UVar) -> Result<(), SynthesisError>;
}
Expand description

RelationGadget is the in-circuit counterpart of Relation.

Required Methods§

Source

fn check_relation(&self, w: &WVar, u: &UVar) -> Result<(), SynthesisError>

RelationGadget::check_relation generates constraints enforcing that w and u satisfy the relation.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§

Source§

impl<WVar, UVar, A: ArithRelationGadget<WVar, UVar>> RelationGadget<WVar, UVar> for A