Module Upat.Pattern_matcher
make rs is the pattern matcher that tries rs in order. Rules are dispatched by the candidate node's root op before structural matching.
Raises Invalid_argument if a top-level pattern has no root op.
val make_with_ctx : 'ctx rule_with_ctx list -> 'ctx with_ctxmake_with_ctx rs is the context-sensitive variant of make.
Raises Invalid_argument if a top-level pattern has no root op.
rewrite pm u tries each rule of pm in order. For each rule whose pattern matches u, the callback is invoked with every binding set produced by match_; the first Some _ return is the result. A callback result physically equal to the candidate node is ignored. None means no rule (with any binding) fired.
rewrite_with_ctx pm ~ctx u is like rewrite except callbacks receive ctx.