[−][src]Trait egg::Condition
A condition to check in a ConditionalApplier
.
See the ConditionalApplier
docs.
Notably, any function (Fn
) that doesn't mutate other state
and matches the signature of check
implements Condition
.
Required methods
fn check(&self, egraph: &mut EGraph<L, M>, eclass: Id, subst: &Subst) -> bool
Check a condition.
eclass
is the eclass Id
where the match (subst
) occured.
If this is true, then the ConditionalApplier
will fire.
Implementors
impl<L, M, A1, A2> Condition<L, M> for ConditionEqual<A1, A2> where
L: Language,
M: Metadata<L>,
A1: Applier<L, M>,
A2: Applier<L, M>,
[src]
L: Language,
M: Metadata<L>,
A1: Applier<L, M>,
A2: Applier<L, M>,
impl<L, M, F> Condition<L, M> for F where
L: Language,
M: Metadata<L>,
F: Fn(&mut EGraph<L, M>, Id, &Subst) -> bool,
[src]
L: Language,
M: Metadata<L>,
F: Fn(&mut EGraph<L, M>, Id, &Subst) -> bool,