Trait halo2_middleware::expression::Variable

source ·
pub trait Variable: Clone + Copy + Debug + Display + Eq + PartialEq {
    // Required methods
    fn degree(&self) -> usize;
    fn write_identifier<W: Write>(&self, writer: &mut W) -> Result<()>;

    // Provided method
    fn complexity(&self) -> usize { ... }
}

Required Methods§

source

fn degree(&self) -> usize

Degree that an expression would have if it was only this variable.

source

fn write_identifier<W: Write>(&self, writer: &mut W) -> Result<()>

Write an identifier of the variable. If two variables have the same identifier, they must be the same variable.

Provided Methods§

source

fn complexity(&self) -> usize

Approximate the computational complexity an expression would have if it was only this variable.

Object Safety§

This trait is not object safe.

Implementors§