The match engine

The engine is the mutable driver behind every match function — most users never touch it. Reuse it via reset! when matching the same pattern against many subjects, or drive it manually via next_match! for custom enumeration.

MatchMaker.next_match! — Function
next_match!(eng::MatchEngine) -> Bool

Advance eng to the next complete alternative. Returns false when the search space is exhausted. A complete match leaves bindings on the trail; the frames stay live so a further call resumes enumeration.

source
MatchMaker.reset! — Function
reset!(
    eng::MatchEngine,
    subj::IRStructure{SymReal},
    sroot::Int32
) -> MatchEngine

Rebind eng to a new site (subj/sroot) for a fresh search: release live frames to the pool, unwind all bindings, and re-push the root frame. Buffers keep their capacity — this is the per-site reset path of RuleWorkspace (REWRITING.md §4).

source
MatchMaker.FrameStatus — Module
FrameStatus

Result of one step! call on a MatchFrame: Produced (one complete alternative, frame stays live for more), Matched (obligation satisfied, no resumable alternatives), Failed (exhausted).

source