pub trait Identity<T> {
// Required methods
fn is_identity(&self) -> bool;
fn identity(w_out: usize, w_in: usize) -> Self;
}Expand description
Trait related to buffer gates. If the gate doesn’t change its input value (ie adding zero, multiplying by one), then we say this is an “identity” gate, eligible to be folded out. !
Required Methods§
fn is_identity(&self) -> bool
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.