forked from nikodemus/esrap
-
Notifications
You must be signed in to change notification settings - Fork 12
/
esrap.asd
135 lines (118 loc) · 5.82 KB
/
esrap.asd
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
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
;;;; Copyright (c) 2007-2013 Nikodemus Siivola <[email protected]>
;;;; Copyright (c) 2012-2024 Jan Moringen <[email protected]>
;;;;
;;;; Permission is hereby granted, free of charge, to any person
;;;; obtaining a copy of this software and associated documentation files
;;;; (the "Software"), to deal in the Software without restriction,
;;;; including without limitation the rights to use, copy, modify, merge,
;;;; publish, distribute, sublicense, and/or sell copies of the Software,
;;;; and to permit persons to whom the Software is furnished to do so,
;;;; subject to the following conditions:
;;;;
;;;; THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
;;;; EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
;;;; MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
;;;; IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
;;;; CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
;;;; TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
;;;; SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
(defsystem "esrap"
:version "0.19"
:description "A Packrat / Parsing Grammar / TDPL parser for Common Lisp."
:long-description "A Packrat / Parsing Grammar / TDPL parser for Common Lisp.
Notable features include
* dynamic redefinition of nonterminals
* inline grammars
* semantic predicates
* introspective facilities (describing grammars,
tracing, setting breaks)
* left-recursive grammars
* functions as terminals
* accurate, customizable parse error reports
See README.org and :homepage for more
information."
:author ("Nikodemus Siivola <[email protected]>"
"Jan Moringen <[email protected]>")
:maintainer "Jan Moringen <[email protected]>"
:homepage "https://scymtym.github.io/esrap"
:bug-tracker "https://github.com/scymtym/esrap/issues"
:source-control (:git "https://github.com/scymtym/esrap.git")
:licence "MIT"
:depends-on ("alexandria"
"trivial-with-current-source-form")
:components ((:module "early"
:pathname "src"
:serial t
:components ((:file "package")
(:file "types")
(:file "protocol")
(:file "variables")
(:file "conditions")
(:file "expressions")
(:file "rule")
(:file "results")))
(:module "cache"
:pathname "src/cache"
:depends-on ("early")
:serial t
:components ((:file "chunk")
(:file "packrat")))
(:module "src"
:depends-on ("early" "cache")
:serial t
:components ((:file "context")
(:file "evaluator")
(:file "macros")
(:file "interface")
(:file "editor-support")))
(:module "examples"
:components ((:static-file "sexp.lisp")
(:static-file "symbol-table.lisp")
(:static-file "left-recursion.lisp")
(:static-file "function-terminals.lisp")))
(:static-file "README.org"))
:in-order-to ((test-op (test-op "esrap/tests"))))
(defmethod perform :after ((op load-op) (sys (eql (find-system "esrap"))))
;; Since version 0.19
;; * DEFRULE accepts a :USE-CACHE option
;; Since version 0.16
;; * DEFRULE accepts an :ERROR-REPORT option
;; Since version 0.15
;; * All transforms that support it, can access bounds via &BOUNDS.
;; Since version 0.14
(pushnew :esrap.lookahead *features*)
(pushnew :esrap.lookbehind *features*)
;; Since version 0.13
(pushnew :esrap.expression-start-terminals *features*)
;; Since version 0.12
(pushnew :esrap.function-terminals *features*)
;; Since version 0.11
(pushnew :esrap.multiple-transforms *features*)
;; Since version 0.10
(pushnew :esrap.can-handle-left-recursion *features*)
;; For consistency with examples which contain (require :esrap).
(provide :esrap))
(defsystem "esrap/tests"
:description "Tests for ESRAP."
:author ("Nikodemus Siivola <[email protected]>"
"Jan Moringen <[email protected]>")
:maintainer "Jan Moringen <[email protected]>"
:licence "MIT"
:depends-on ("esrap"
(:version "fiveam" "1.3"))
:serial t
:components ((:module "examples"
:components ((:file "left-recursion")
(:file "function-terminals")))
(:module "test"
:serial t
:components ((:file "package")
(:file "util")
(:file "expressions")
(:file "macros")
(:file "tests")
(:file "stress")
(:file "examples")
(:file "readme"))))
:perform (test-op (operation component)
(uiop:symbol-call '#:esrap-tests '#:run-tests)))