Functions for working with the Meander's match compiler intermediate representation (IR).
Functions for working with the Meander's match compiler intermediate representation (IR).
(branch? node)
true if node has any children, false otherwise.
true if node has any children, false otherwise.
(check? x)
(children node)
Return the child nodes of node, a sequence of ::node.
Return the child nodes of node, a sequence of ::node.
(compile ir fail kind)
(compile* ir fail kind)
(def-remove-unused node)
(defop symbol op params & body)
(defop &form &env symbol op params & body)
(drop-form n target-form kind)
Special value signaling a match failure. Generated code will often utilize this value as for control flow purposes.
Special value signaling a match failure. Generated code will often utilize this value as for control flow purposes.
(fail-form kind)
Returns (list FAIL) if kind is :search,
FAIL otherwise. This is
used when compiling :def nodes to ensure the correct type of data is
returned to code compiled for :call nodes.
Returns `(list FAIL) if kind is :search, `FAIL otherwise. This is used when compiling :def nodes to ensure the correct type of data is returned to code compiled for :call nodes.
(fail? x)
(js-array-equals-form a b)
Form used to test if two arrays a and b are equal in ClojureScript.
Form used to test if two arrays a and b are equal in ClojureScript.
(make-node node new-children)
(merge node-a node-b)
Attempt to merge node-a and node-b. Returns the result of the merge if the merge succeeds. Returns a :branch node with :arms node-a and node-b if not.
Attempt to merge node-a and node-b. Returns the result of the merge if the merge succeeds. Returns a :branch node with :arms node-a and node-b if not.
(node? x)
true if x is a ::node, false otherwise.
true if x is a ::node, false otherwise.
(nodes node)
Return all subnodes of node, a sequence of ::node.
Return all subnodes of node, a sequence of ::node.
(op-bind symbol value then)
(op-branch arms)
(op-check test target then)
(op-check-array target then)
(op-check-array-equals target-1 target-2 then)
(op-check-boolean test then)
(op-check-bounds target length kind then)
(op-check-empty target then)
(op-check-equal target-1 target-2 then)
(op-check-lit target value then)
(op-check-map target then)
(op-check-seq target then)
(op-check-set target then)
(op-check-vector target then)
(op-drop target n kind)
(op-eval form)
(op-fail)
(op-fail? x)
(op-find symbol value body)
(op-load id)
(op-lookup target key)
(op-lvr-bind symbol target then)
(op-lvr-check symbol target then)
(op-mut-bind symbol target then)
(op-mvr-append symbol target then)
(op-mvr-bind symbol target then)
(op-mvr-init symbol then)
(op-nth target index)
(op-pass then)
(op-plus input n m kind return-symbols body-fn then)
(op-return value)
(op-save id body-1 body-2)
(op-search symbol value body)
(op-star input n kind return-symbols body-fn then)
(op-take target n kind)
(op= node op)
(postwalk f node)
(prewalk f node)
(rewrite node)
(rewrite* node)
(rewrite-move-mvr-init-to-top-level node)
(run-find space body-f fail-f)
(run-star-js-array coll rets n body-f then-f)
(run-star-js-array-search coll rets n body-f then-f)
(run-star-seq coll rets n body-f then-f)
(run-star-seq-search coll rets n body-f then-f)
(run-star-vec coll rets n body-f then-f)
(run-star-vec-search coll rets n body-f then-f)
(take-form n target-form kind)
(walk inner outer node)
(zipper node)
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close