pub struct ConditionalApplier<C, A> {
pub condition: C,
pub applier: A,
}
Expand description
Fields§
§condition: C
§applier: A
The inner Applier
to call once condition
passes.
Trait Implementations§
Source§impl<C, A, N, L> Applier<L, N> for ConditionalApplier<C, A>
impl<C, A, N, L> Applier<L, N> for ConditionalApplier<C, A>
Source§fn apply_one(
&self,
egraph: &mut EGraph<L, N>,
eclass: Id,
subst: &Subst,
searcher_ast: Option<&RecExpr<ENodeOrVar<L>>>,
rule_name: Symbol,
) -> Vec<Id>
fn apply_one( &self, egraph: &mut EGraph<L, N>, eclass: Id, subst: &Subst, searcher_ast: Option<&RecExpr<ENodeOrVar<L>>>, rule_name: Symbol, ) -> Vec<Id>
Apply a single substitition. Read more
Source§fn vars(&self) -> Vec<Var>
fn vars(&self) -> Vec<Var>
Returns a list of variables that this Applier assumes are bound. Read more
Source§fn apply_matches(
&self,
egraph: &mut EGraph<L, N>,
matches: &[SearchMatches<'_, L>],
rule_name: Symbol,
) -> Vec<Id>
fn apply_matches( &self, egraph: &mut EGraph<L, N>, matches: &[SearchMatches<'_, L>], rule_name: Symbol, ) -> Vec<Id>
Apply many substititions. Read more
Source§fn get_pattern_ast(&self) -> Option<&RecExpr<ENodeOrVar<L>>>
fn get_pattern_ast(&self) -> Option<&RecExpr<ENodeOrVar<L>>>
For patterns, get the ast directly as a reference.
Source§impl<C, A> Clone for ConditionalApplier<C, A>
impl<C, A> Clone for ConditionalApplier<C, A>
Source§fn clone(&self) -> ConditionalApplier<C, A>
fn clone(&self) -> ConditionalApplier<C, A>
Returns a duplicate 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 moreAuto Trait Implementations§
impl<C, A> Freeze for ConditionalApplier<C, A>
impl<C, A> RefUnwindSafe for ConditionalApplier<C, A>where
C: RefUnwindSafe,
A: RefUnwindSafe,
impl<C, A> Send for ConditionalApplier<C, A>
impl<C, A> Sync for ConditionalApplier<C, A>
impl<C, A> Unpin for ConditionalApplier<C, A>
impl<C, A> UnwindSafe for ConditionalApplier<C, A>where
C: UnwindSafe,
A: 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