-
Notifications
You must be signed in to change notification settings - Fork 149
/
combinators.cljc
34 lines (30 loc) · 954 Bytes
/
combinators.cljc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
(ns instaparse.combinators
"The combinator public API for instaparse"
(:refer-clojure :exclude [cat])
#?(:clj (:use instaparse.macros)
:cljs (:require-macros
[instaparse.macros :refer [defclone]]))
(:require [instaparse.combinators-source :as c]
[instaparse.cfg :as cfg]
[instaparse.abnf :as abnf]))
;; The actual source is in combinators-source.
;; This was necessary to avoid a cyclical dependency in the namespaces.
(defclone Epsilon c/Epsilon)
(defclone opt c/opt)
(defclone plus c/plus)
(defclone star c/star)
(defclone rep c/rep)
(defclone alt c/alt)
(defclone ord c/ord)
(defclone cat c/cat)
(defclone string c/string)
(defclone string-ci c/string-ci)
(defclone unicode-char c/unicode-char)
(defclone regexp c/regexp)
(defclone nt c/nt)
(defclone look c/look)
(defclone neg c/neg)
(defclone hide c/hide)
(defclone hide-tag c/hide-tag)
(defclone ebnf cfg/ebnf)
(defclone abnf abnf/abnf)