Liking cljdoc? Tell your friends :D

meander.syntax.alpha


any-node?clj/s

(any-node? x)
source

any-symbol?clj/s

(any-symbol? x)

true if x is a symbol beginning with _.

true if x is a symbol beginning with _.
sourceraw docstring

childrenclj/smultimethod

(children node)

Return a sequence of all subnodes of node.

Return a sequence of all subnodes of node.
sourceraw docstring

children-dispatchclj/s

(children-dispatch node)
source

dataclj/s

(data node)
source

defsyntaxclj/s≠macro

clj
(defsyntax name docstring? meta? arglist & body)
cljs
(defsyntax &form &env & args)

EXPERIMENTAL Like defn but for defining new pattern syntax by extending the parser. When parsing, if a seq is encountered starting with a symbol which can be resolved to the created var then the tail of the seq is applied to the var and the result is parsed.

Example

(defsyntax re [regex] `(~'pred (fn [s#] (and (string? s#) (re-matches ~regex s#)))))

(require '[meander.match.alpha :as r.match])

(r.match "elf" (re #"[a-z]+") :okay!) ;; => :okay

EXPERIMENTAL Like defn but for defining new pattern syntax by
extending the parser. When parsing, if a seq is encountered starting
with a symbol which can be resolved to the created var then the tail
of the seq is applied to the var and the result is parsed.

Example

(defsyntax re [regex]
  `(~'pred
    (fn [s#]
      (and (string? s#)
           (re-matches ~regex s#)))))

(require '[meander.match.alpha :as r.match])

(r.match "elf"
  (re #"[a-z]+")
  :okay!)
;; => :okay
source (clj)source (cljs)raw docstring

dsj-node?clj/s

(dsj-node? x)
source

expand-usr-opclj/smultimethod

(expand-usr-op usr-node)
source

expand-usr-op-dispatchclj/s

(expand-usr-op-dispatch [_ {op :op}])
source

expand-usr-opsclj/s

(expand-usr-ops node)
source

ground?clj/smultimethod

(ground? node)

true if node is ground i.e. it contains no variables or is not a match operator.

true if node is ground i.e. it contains no variables or is not a
match operator.
sourceraw docstring

logic-variable-form?clj/s

(logic-variable-form? x)

true if x is in the form of a logic variable i.e. a simple symbol with a name beginning with ?.

true if x is in the form of a logic variable i.e. a simple symbol
with a name beginning with \?.
sourceraw docstring

logic-variablesclj/s

(logic-variables node)

Return all :lvr nodes in node.

Return all :lvr nodes in node.
sourceraw docstring

lvr-node?clj/s

(lvr-node? x)
source

max-lengthclj/smultimethod

(max-length node)
sourceraw docstring

memory-variable-form?clj/s

(memory-variable-form? x)

true if x is in the form of a memory variable i.e. a simple symbol with a name beginning with !.

true if x is in the form of a memory variable i.e. a simple symbol
with a name beginning with \!.
sourceraw docstring

memory-variablesclj/s

(memory-variables node)

Return all :mvr nodes in node.

Return all :mvr nodes in node.
sourceraw docstring

min-lengthclj/smultimethod

(min-length node)
sourceraw docstring

mvr-node?clj/s

(mvr-node? x)
source

n-or-more-symbol?clj/s

(n-or-more-symbol? x)
source

node?clj/s

(node? x)
source

parseclj/s

(parse x)
source

partition-symbol?clj/s

(partition-symbol? x)
source

pattern-opclj/smultimethod

(pattern-op seq)
source

pattern-op-dispatchclj/s

(pattern-op-dispatch x)

Dispatch function for pattern-op.

Dispatch function for pattern-op.
sourceraw docstring

proper-subnodesclj/s

(proper-subnodes node)

Return the all subnodes in node excluding node.

Return the all subnodes in node excluding node.
sourceraw docstring

quote-form?clj/s

(quote-form? x)

true if x is in the form (quote x).

true if x is in the form (quote x).
sourceraw docstring

rankclj/smultimethod

(rank node)
sourceraw docstring

re-matches?clj/s

(re-matches? re s)
source (clj)source (cljs)

search?clj/smultimethod

(search? node)
sourceraw docstring

subnodesclj/s

(subnodes node)

Return a sequence of all subnodes of node.

Return a sequence of all subnodes of node.
sourceraw docstring

tagclj/s

(tag node)
source

unparseclj/smultimethod

(unparse node)

In pre-order fashion rewrite a node into a Clojure form.

In pre-order fashion rewrite a node into a Clojure form.
sourceraw docstring

unquote-form?clj/s

(unquote-form? x)

true if x is in the form (clojure.core/unquote x).

true if x is in the form (clojure.core/unquote x).
sourceraw docstring

unquote-splicing-form?clj/s

(unquote-splicing-form? x)

true if x is in the form (clojure.core/unquote-splicing x).

true if x is in the form (clojure.core/unquote-splicing x).
sourceraw docstring

variable-length?clj/s

(variable-length? node)

true if node may have a variable length.

true if node may have a variable length.
sourceraw docstring

variable-node?clj/s

(variable-node? x)
source

variablesclj/s

(variables node)

Return all :lvr and :mvr nodes in node.

Return all :lvr and :mvr nodes in node.
sourceraw docstring

zero-or-more-symbol?clj/s

(zero-or-more-symbol? x)
source

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close