Added Scott Bell's implementation of ASH.
[parenscript.git] / src / package.lisp
blob64e31b0a847840f022214991c04472ecc644d141
1 (in-package #:cl)
3 (pushnew :parenscript *features*)
5 (eval-when (:compile-toplevel :load-toplevel :execute)
6 (named-readtables:defreadtable :parenscript
7 (:merge :standard)
8 (:case :invert)))
10 (named-readtables:in-readtable :parenscript)
12 (defpackage #:parenscript
13 (:use #:cl #:anaphora #:named-readtables)
14 (:nicknames #:ps)
15 (:export
16 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
17 ;;; Compiler interface
19 ;; compiler
20 #:*js-target-version*
21 #:ps
22 #:*parenscript-stream*
23 #:ps-to-stream
24 #:ps-doc
25 #:ps-doc*
26 #:ps*
27 #:ps-inline
28 #:ps-inline*
29 #:*ps-read-function*
30 #:ps-compile-file
31 #:ps-compile-stream
32 ;; for parenscript macro definition within lisp
33 #:defpsmacro
34 #:defmacro+ps
35 #:import-macros-from-lisp
36 #:*ps-defined-operators*
38 ;; gensym
39 #:ps-gensym
40 #:with-ps-gensyms
41 #:ps-once-only
42 #:*ps-gensym-counter*
44 ;; naming and namespaces
45 #:in-package
46 #:use-package
47 #:ps-package-prefix
48 #:obfuscate-package
49 #:unobfuscate-package
51 ;; printer
52 #:symbol-to-js-string
53 #:*js-string-delimiter*
54 #:*js-inline-string-delimiter*
55 #:*ps-print-pretty*
56 #:*indent-num-spaces*
58 ;; deprecated interface
59 #:define-script-symbol-macro
60 #:gen-js-name
61 #:with-unique-js-names
62 #:defjsmacro
63 #:js-compile
64 #:js-inline
65 #:js-inline*
66 #:js
67 #:js*
68 #:symbol-to-js
69 #:slot-value
70 #:compile-script
71 #:defmacro/ps
72 #:%
73 #:==
74 #:===
75 #:!=
76 #:!==
77 #:labeled-for
78 #:do-set-timeout
79 #:concat-string
80 #:with
81 #:label
83 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
84 ;;; Language
86 ;; literals
87 #:t
88 #:f
89 #.(symbol-name 'nil) ; for case-sensitive Lisps like some versions of Allegro
90 #:this
91 #:undefined
92 #:{}
94 ;; keywords
95 #:break
96 #:continue
98 ;; array literals
99 #:array
100 #:list
101 #:aref
102 #:elt
103 #:make-array
104 #:[]
106 ;; operators
107 ;; logical boolean
108 #:not
109 #:and
110 #:or
112 ;; bitwise boolean
113 #:logand
114 #:logior
115 #:logxor
116 #:lognot
117 #:ash
121 #:rem
126 #:<=
127 #:>=
128 #:incf
129 #:decf
130 #:equal
131 #:eql
132 #:eq
135 ;; compile-time stuff
136 #:eval-when
138 ;; body forms
139 #:progn
141 ;; object literals
142 #:create
143 #:with-slots
145 ;; if
146 #:if
147 #:when
148 #:unless
150 ;; single argument statements
151 #:return
152 #:return-from
153 #:throw
155 ;; single argument expressions
156 #:delete
157 #:typeof
158 #:instanceof
159 #:new
161 ;; assignment and binding
162 #:setf
163 #:defsetf
164 #:psetf
165 #:setq
166 #:psetq
167 #:let*
168 #:let
170 ;; variables
171 #:var
172 #:defvar
174 ;; iteration
175 #:for
176 #:for-in
177 #:while
178 #:do
179 #:do*
180 #:dotimes
181 #:dolist
182 #:loop
184 ;; case
185 #:switch
186 #:case
187 #:default
189 ;; try throw catch
190 #:try
192 ;; regex literals
193 #:regex
195 ;; function definition
196 #:defun
197 #:lambda
198 #:flet
199 #:labels
201 ;; lambda lists
202 #:&key
203 #:&rest
204 #:&body
205 #:&optional
206 #:&aux
207 #:&environment
208 #:&key-object
210 ;; slot access
211 #:with-slots
212 #:getprop
213 #:in
215 ;; macros
216 #:macrolet
217 #:symbol-macrolet
218 #:define-symbol-macro
219 #:define-ps-symbol-macro
220 #:defmacro
222 ;; lisp eval
223 #:lisp
225 ;; v v v STUFF WE SHOULD PROBABLY MOVE TO OTHER LIBS v v v
227 ;; html generator for javascript
228 #:*ps-html-empty-tag-aware-p*
229 #:*ps-html-mode*
230 #:ps-html
231 #:who-ps-html
233 ;; utils
234 #:max
235 #:min
236 #:floor
237 #:ceiling
238 #:round
239 #:sin
240 #:cos
241 #:tan
242 #:asin
243 #:acos
244 #:atan
245 #:pi
246 #:sinh
247 #:cosh
248 #:tanh
249 #:asinh
250 #:acosh
251 #:atanh
252 #:1+
253 #:1-
254 #:abs
255 #:evenp
256 #:oddp
257 #:exp
258 #:expt
259 #:log
260 #:sqrt
261 #:random
262 #:ignore-errors
263 #:concatenate
264 #:stringify
265 #:length
266 #:defined
267 #:undefined
269 #:chain
270 #:stringp
271 #:numberp
272 #:functionp
273 #:objectp
274 #:append
275 #:apply
276 #:destructuring-bind
278 ;; DOM accessing utils
279 #:inner-html
280 #:uri-encode
281 #:attribute
282 #:offset
283 #:scroll
284 #:inner
285 #:client
287 ;; js runtime utils
288 #:*ps-lisp-library*
289 #:mapcar
290 #:map-into
291 #:map
292 #:member
293 #:append
294 #:set-difference