Liking cljdoc? Tell your friends :D

jasentaa.parser.combinators


and-thenclj/s

(and-then p1 p2)

(ab)

(ab)
sourceraw docstring

any-ofclj/s

(any-of & ps)
source

chain-leftclj/s

(chain-left p op)
(chain-left p op a)

Parse repeated applications of a parser p, separated by applications of a parser op whose result value is an operator that is assumed to associate to the left, and which is used to combine the results from the p parsers.

Parse repeated applications of a parser p, separated by
applications of a parser op whose result value is an
operator that is assumed to associate to the left, and
which is used to combine the results from the p parsers.
sourceraw docstring

chain-rightclj/s

(chain-right p op)
(chain-right p op a)

Parse repeated applications of a parser p, separated by applications of a parser op whose result value is an operator that is assumed to associate to the right, and which is used to combine the results from the p parsers.

Parse repeated applications of a parser p, separated by
applications of a parser op whose result value is an
operator that is assumed to associate to the right, and
which is used to combine the results from the p parsers.
 
sourceraw docstring

choiceclj/s

(choice p1 p2)

(a|b)

Deterministic choice (+++) operator. Has the same behaviour as or-else, except that at most one result is returned.

(a|b)

Deterministic choice (+++) operator. Has the same behaviour
as `or-else`, except that at most one result is returned.
sourceraw docstring

manyclj/s

(many p)

(a*)

Parse repeated applications of a parser; the many combinator permits zero or more applications of the parser.

(a*)

Parse repeated applications of a parser; the many combinator
permits zero or more applications of the parser.
sourceraw docstring

optionalclj/s

(optional p)

(a?)

Parse zero or one applications of a parser.

(a?)

Parse zero or one applications of a parser.
sourceraw docstring

or-elseclj/s

(or-else p1 p2)

(a|b)

Non-deterministic choice (++) operator. Applies both parsers to the argument string, and appends their list of results.

(a|b)

Non-deterministic choice (++) operator. Applies both parsers
to the argument string, and appends their list of results.
sourceraw docstring

plusclj/s

(plus p)

(a+) is equivalent to (aa*)

Parse repeated applications of a parser; the plus combinator permits one or more applications of the parser.

(a+) is equivalent to (aa*)

Parse repeated applications of a parser; the plus combinator
permits one or more applications of the parser.
sourceraw docstring

separated-byclj/s

(separated-by p sep)

Parse repeated applications of a parser p, separated by applications of a parser sep whose result values are thrown away.

This parser will process at least one application of p. For a list of zero or more, use:

(optional (separated-by p sep))

Parse repeated applications of a parser p, separated by
applications of a parser sep whose result values are
thrown away.

This parser will process at least one application of p.
For a list of zero or more, use:

  (optional (separated-by p sep))
sourceraw docstring

spaceclj/s

Parse a single space, tab, newline or carriage-return.

Parse a single space, tab, newline or carriage-return.
sourceraw docstring

spacesclj/s

Parse a string of (zero or more) spaces, tabs, and newlines.

Parse a string of (zero or more) spaces, tabs, and newlines.
sourceraw docstring

stringclj/s

(string input)

Parse a specific string.

Parse a specific string.
sourceraw docstring

symbclj/s

Parse a symbolic token.

Parse a symbolic token.
sourceraw docstring

tokenclj/s

(token p)

Parse a token using a parser p, throwing away any trailing space.

Parse a token using a parser p, throwing away any trailing space.
sourceraw docstring

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

× close