Struct circomspect_program_structure::intermediate_representation::value_meta::ValueKnowledge
source · [−]pub struct ValueKnowledge { /* private fields */ }Implementations
sourceimpl ValueKnowledge
impl ValueKnowledge
pub fn new() -> ValueKnowledge
sourcepub fn set_reduces_to(&mut self, reduces_to: ValueReduction) -> bool
pub fn set_reduces_to(&mut self, reduces_to: ValueReduction) -> bool
Sets the value of the node. Returns true on the first update.
sourcepub fn get_reduces_to(&self) -> Option<&ValueReduction>
pub fn get_reduces_to(&self) -> Option<&ValueReduction>
Gets the value of the node. Returns None if the value is unknown.
sourcepub fn is_constant(&self) -> bool
pub fn is_constant(&self) -> bool
Returns true if the value of the node is known.
sourcepub fn is_boolean(&self) -> bool
pub fn is_boolean(&self) -> bool
Returns true if the value of the node is a boolean.
sourcepub fn is_field_element(&self) -> bool
pub fn is_field_element(&self) -> bool
Returns true if the value of the node is a field element.
Trait Implementations
sourceimpl Clone for ValueKnowledge
impl Clone for ValueKnowledge
sourcefn clone(&self) -> ValueKnowledge
fn clone(&self) -> ValueKnowledge
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read more
sourceimpl Default for ValueKnowledge
impl Default for ValueKnowledge
sourcefn default() -> ValueKnowledge
fn default() -> ValueKnowledge
Returns the “default value” for a type. Read more
Auto Trait Implementations
impl RefUnwindSafe for ValueKnowledge
impl Send for ValueKnowledge
impl Sync for ValueKnowledge
impl Unpin for ValueKnowledge
impl UnwindSafe for ValueKnowledge
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more