7
|
1 " Vim syntax file
|
|
2 " Language: Lisp
|
|
3 " Maintainer: Dr. Charles E. Campbell, Jr. <NdrOchipS@PcampbellAfamily.Mbiz>
|
2662
|
4 " Last Change: Nov 16, 2010
|
|
5 " Version: 22
|
507
|
6 " URL: http://mysite.verizon.net/astronaut/vim/index.html#vimlinks_syntax
|
7
|
7 "
|
|
8 " Thanks to F Xavier Noria for a list of 978 Common Lisp symbols
|
|
9 " taken from the HyperSpec
|
1624
|
10 " Clisp additions courtesy of http://clisp.cvs.sourceforge.net/*checkout*/clisp/clisp/emacs/lisp.vim
|
7
|
11
|
557
|
12 " ---------------------------------------------------------------------
|
556
|
13 " Load Once: {{{1
|
|
14 " For vim-version 5.x: Clear all syntax items
|
|
15 " For vim-version 6.x: Quit when a syntax file was already loaded
|
7
|
16 if version < 600
|
|
17 syntax clear
|
|
18 elseif exists("b:current_syntax")
|
|
19 finish
|
|
20 endif
|
|
21
|
|
22 if version >= 600
|
1624
|
23 setlocal iskeyword=38,42,43,45,47-58,60-62,64-90,97-122,_
|
7
|
24 else
|
1624
|
25 set iskeyword=38,42,43,45,47-58,60-62,64-90,97-122,_
|
|
26 endif
|
|
27
|
|
28 if exists("g:lispsyntax_ignorecase") || exists("g:lispsyntax_clisp")
|
|
29 set ignorecase
|
7
|
30 endif
|
|
31
|
557
|
32 " ---------------------------------------------------------------------
|
556
|
33 " Clusters: {{{1
|
1624
|
34 syn cluster lispAtomCluster contains=lispAtomBarSymbol,lispAtomList,lispAtomNmbr0,lispComment,lispDecl,lispFunc,lispLeadWhite
|
2662
|
35 syn cluster lispBaseListCluster contains=lispAtom,lispAtomBarSymbol,lispAtomMark,lispBQList,lispBarSymbol,lispComment,lispConcat,lispDecl,lispFunc,lispKey,lispList,lispNumber,lispEscapeSpecial,lispSymbol,lispVar,lispLeadWhite
|
556
|
36 if exists("g:lisp_instring")
|
1624
|
37 syn cluster lispListCluster contains=@lispBaseListCluster,lispString,lispInString,lispInStringString
|
556
|
38 else
|
1624
|
39 syn cluster lispListCluster contains=@lispBaseListCluster,lispString
|
556
|
40 endif
|
7
|
41
|
1125
|
42 syn case ignore
|
|
43
|
557
|
44 " ---------------------------------------------------------------------
|
556
|
45 " Lists: {{{1
|
1624
|
46 syn match lispSymbol contained ![^()'`,"; \t]\+!
|
|
47 syn match lispBarSymbol contained !|..\{-}|!
|
556
|
48 if exists("g:lisp_rainbow") && g:lisp_rainbow != 0
|
1624
|
49 syn region lispParen0 matchgroup=hlLevel0 start="`\=(" end=")" skip="|.\{-}|" contains=@lispListCluster,lispParen1
|
|
50 syn region lispParen1 contained matchgroup=hlLevel1 start="`\=(" end=")" skip="|.\{-}|" contains=@lispListCluster,lispParen2
|
|
51 syn region lispParen2 contained matchgroup=hlLevel2 start="`\=(" end=")" skip="|.\{-}|" contains=@lispListCluster,lispParen3
|
|
52 syn region lispParen3 contained matchgroup=hlLevel3 start="`\=(" end=")" skip="|.\{-}|" contains=@lispListCluster,lispParen4
|
|
53 syn region lispParen4 contained matchgroup=hlLevel4 start="`\=(" end=")" skip="|.\{-}|" contains=@lispListCluster,lispParen5
|
|
54 syn region lispParen5 contained matchgroup=hlLevel5 start="`\=(" end=")" skip="|.\{-}|" contains=@lispListCluster,lispParen6
|
|
55 syn region lispParen6 contained matchgroup=hlLevel6 start="`\=(" end=")" skip="|.\{-}|" contains=@lispListCluster,lispParen7
|
|
56 syn region lispParen7 contained matchgroup=hlLevel7 start="`\=(" end=")" skip="|.\{-}|" contains=@lispListCluster,lispParen8
|
|
57 syn region lispParen8 contained matchgroup=hlLevel8 start="`\=(" end=")" skip="|.\{-}|" contains=@lispListCluster,lispParen9
|
556
|
58 syn region lispParen9 contained matchgroup=hlLevel9 start="`\=(" end=")" skip="|.\{-}|" contains=@lispListCluster,lispParen0
|
7
|
59 else
|
1624
|
60 syn region lispList matchgroup=Delimiter start="(" skip="|.\{-}|" matchgroup=Delimiter end=")" contains=@lispListCluster
|
|
61 syn region lispBQList matchgroup=PreProc start="`(" skip="|.\{-}|" matchgroup=PreProc end=")" contains=@lispListCluster
|
7
|
62 endif
|
556
|
63
|
557
|
64 " ---------------------------------------------------------------------
|
556
|
65 " Atoms: {{{1
|
1624
|
66 syn match lispAtomMark "'"
|
|
67 syn match lispAtom "'("me=e-1 contains=lispAtomMark nextgroup=lispAtomList
|
|
68 syn match lispAtom "'[^ \t()]\+" contains=lispAtomMark
|
|
69 syn match lispAtomBarSymbol !'|..\{-}|! contains=lispAtomMark
|
|
70 syn region lispAtom start=+'"+ skip=+\\"+ end=+"+
|
2662
|
71 syn region lispAtomList contained matchgroup=Special start="(" skip="|.\{-}|" matchgroup=Special end=")" contains=@lispAtomCluster,lispString,lispEscapeSpecial
|
1624
|
72 syn match lispAtomNmbr contained "\<\d\+"
|
|
73 syn match lispLeadWhite contained "^\s\+"
|
7
|
74
|
557
|
75 " ---------------------------------------------------------------------
|
556
|
76 " Standard Lisp Functions and Macros: {{{1
|
1624
|
77 syn keyword lispFunc * find-method pprint-indent
|
|
78 syn keyword lispFunc ** find-package pprint-linear
|
|
79 syn keyword lispFunc *** find-restart pprint-logical-block
|
|
80 syn keyword lispFunc + find-symbol pprint-newline
|
|
81 syn keyword lispFunc ++ finish-output pprint-pop
|
|
82 syn keyword lispFunc +++ first pprint-tab
|
|
83 syn keyword lispFunc - fixnum pprint-tabular
|
|
84 syn keyword lispFunc / flet prin1
|
|
85 syn keyword lispFunc // float prin1-to-string
|
|
86 syn keyword lispFunc /// float-digits princ
|
|
87 syn keyword lispFunc /= float-precision princ-to-string
|
|
88 syn keyword lispFunc 1+ float-radix print
|
|
89 syn keyword lispFunc 1- float-sign print-not-readable
|
|
90 syn keyword lispFunc < floating-point-inexact print-not-readable-object
|
|
91 syn keyword lispFunc <= floating-point-invalid-operation print-object
|
|
92 syn keyword lispFunc = floating-point-overflow print-unreadable-object
|
|
93 syn keyword lispFunc > floating-point-underflow probe-file
|
|
94 syn keyword lispFunc >= floatp proclaim
|
|
95 syn keyword lispFunc abort floor prog
|
|
96 syn keyword lispFunc abs fmakunbound prog*
|
|
97 syn keyword lispFunc access force-output prog1
|
|
98 syn keyword lispFunc acons format prog2
|
|
99 syn keyword lispFunc acos formatter progn
|
|
100 syn keyword lispFunc acosh fourth program-error
|
|
101 syn keyword lispFunc add-method fresh-line progv
|
|
102 syn keyword lispFunc adjoin fround provide
|
|
103 syn keyword lispFunc adjust-array ftruncate psetf
|
|
104 syn keyword lispFunc adjustable-array-p ftype psetq
|
|
105 syn keyword lispFunc allocate-instance funcall push
|
|
106 syn keyword lispFunc alpha-char-p function pushnew
|
|
107 syn keyword lispFunc alphanumericp function-keywords putprop
|
|
108 syn keyword lispFunc and function-lambda-expression quote
|
|
109 syn keyword lispFunc append functionp random
|
|
110 syn keyword lispFunc apply gbitp random-state
|
|
111 syn keyword lispFunc applyhook gcd random-state-p
|
|
112 syn keyword lispFunc apropos generic-function rassoc
|
|
113 syn keyword lispFunc apropos-list gensym rassoc-if
|
|
114 syn keyword lispFunc aref gentemp rassoc-if-not
|
|
115 syn keyword lispFunc arithmetic-error get ratio
|
|
116 syn keyword lispFunc arithmetic-error-operands get-decoded-time rational
|
|
117 syn keyword lispFunc arithmetic-error-operation get-dispatch-macro-character rationalize
|
|
118 syn keyword lispFunc array get-internal-real-time rationalp
|
|
119 syn keyword lispFunc array-dimension get-internal-run-time read
|
|
120 syn keyword lispFunc array-dimension-limit get-macro-character read-byte
|
|
121 syn keyword lispFunc array-dimensions get-output-stream-string read-char
|
|
122 syn keyword lispFunc array-displacement get-properties read-char-no-hang
|
|
123 syn keyword lispFunc array-element-type get-setf-expansion read-delimited-list
|
|
124 syn keyword lispFunc array-has-fill-pointer-p get-setf-method read-eval-print
|
|
125 syn keyword lispFunc array-in-bounds-p get-universal-time read-from-string
|
|
126 syn keyword lispFunc array-rank getf read-line
|
|
127 syn keyword lispFunc array-rank-limit gethash read-preserving-whitespace
|
|
128 syn keyword lispFunc array-row-major-index go read-sequence
|
|
129 syn keyword lispFunc array-total-size graphic-char-p reader-error
|
|
130 syn keyword lispFunc array-total-size-limit handler-bind readtable
|
|
131 syn keyword lispFunc arrayp handler-case readtable-case
|
|
132 syn keyword lispFunc ash hash-table readtablep
|
|
133 syn keyword lispFunc asin hash-table-count real
|
|
134 syn keyword lispFunc asinh hash-table-p realp
|
|
135 syn keyword lispFunc assert hash-table-rehash-size realpart
|
|
136 syn keyword lispFunc assoc hash-table-rehash-threshold reduce
|
|
137 syn keyword lispFunc assoc-if hash-table-size reinitialize-instance
|
|
138 syn keyword lispFunc assoc-if-not hash-table-test rem
|
|
139 syn keyword lispFunc atan host-namestring remf
|
|
140 syn keyword lispFunc atanh identity remhash
|
|
141 syn keyword lispFunc atom if remove
|
|
142 syn keyword lispFunc base-char if-exists remove-duplicates
|
|
143 syn keyword lispFunc base-string ignorable remove-if
|
|
144 syn keyword lispFunc bignum ignore remove-if-not
|
|
145 syn keyword lispFunc bit ignore-errors remove-method
|
|
146 syn keyword lispFunc bit-and imagpart remprop
|
|
147 syn keyword lispFunc bit-andc1 import rename-file
|
|
148 syn keyword lispFunc bit-andc2 in-package rename-package
|
|
149 syn keyword lispFunc bit-eqv in-package replace
|
|
150 syn keyword lispFunc bit-ior incf require
|
|
151 syn keyword lispFunc bit-nand initialize-instance rest
|
|
152 syn keyword lispFunc bit-nor inline restart
|
|
153 syn keyword lispFunc bit-not input-stream-p restart-bind
|
|
154 syn keyword lispFunc bit-orc1 inspect restart-case
|
|
155 syn keyword lispFunc bit-orc2 int-char restart-name
|
|
156 syn keyword lispFunc bit-vector integer return
|
|
157 syn keyword lispFunc bit-vector-p integer-decode-float return-from
|
|
158 syn keyword lispFunc bit-xor integer-length revappend
|
|
159 syn keyword lispFunc block integerp reverse
|
|
160 syn keyword lispFunc boole interactive-stream-p room
|
|
161 syn keyword lispFunc boole-1 intern rotatef
|
|
162 syn keyword lispFunc boole-2 internal-time-units-per-second round
|
|
163 syn keyword lispFunc boole-and intersection row-major-aref
|
|
164 syn keyword lispFunc boole-andc1 invalid-method-error rplaca
|
|
165 syn keyword lispFunc boole-andc2 invoke-debugger rplacd
|
|
166 syn keyword lispFunc boole-c1 invoke-restart safety
|
|
167 syn keyword lispFunc boole-c2 invoke-restart-interactively satisfies
|
|
168 syn keyword lispFunc boole-clr isqrt sbit
|
|
169 syn keyword lispFunc boole-eqv keyword scale-float
|
|
170 syn keyword lispFunc boole-ior keywordp schar
|
|
171 syn keyword lispFunc boole-nand labels search
|
|
172 syn keyword lispFunc boole-nor lambda second
|
|
173 syn keyword lispFunc boole-orc1 lambda-list-keywords sequence
|
|
174 syn keyword lispFunc boole-orc2 lambda-parameters-limit serious-condition
|
|
175 syn keyword lispFunc boole-set last set
|
|
176 syn keyword lispFunc boole-xor lcm set-char-bit
|
|
177 syn keyword lispFunc boolean ldb set-difference
|
|
178 syn keyword lispFunc both-case-p ldb-test set-dispatch-macro-character
|
|
179 syn keyword lispFunc boundp ldiff set-exclusive-or
|
|
180 syn keyword lispFunc break least-negative-double-float set-macro-character
|
|
181 syn keyword lispFunc broadcast-stream least-negative-long-float set-pprint-dispatch
|
|
182 syn keyword lispFunc broadcast-stream-streams least-negative-normalized-double-float set-syntax-from-char
|
|
183 syn keyword lispFunc built-in-class least-negative-normalized-long-float setf
|
|
184 syn keyword lispFunc butlast least-negative-normalized-short-float setq
|
|
185 syn keyword lispFunc byte least-negative-normalized-single-float seventh
|
|
186 syn keyword lispFunc byte-position least-negative-short-float shadow
|
|
187 syn keyword lispFunc byte-size least-negative-single-float shadowing-import
|
|
188 syn keyword lispFunc call-arguments-limit least-positive-double-float shared-initialize
|
|
189 syn keyword lispFunc call-method least-positive-long-float shiftf
|
|
190 syn keyword lispFunc call-next-method least-positive-normalized-double-float short-float
|
|
191 syn keyword lispFunc capitalize least-positive-normalized-long-float short-float-epsilon
|
|
192 syn keyword lispFunc car least-positive-normalized-short-float short-float-negative-epsilon
|
|
193 syn keyword lispFunc case least-positive-normalized-single-float short-site-name
|
|
194 syn keyword lispFunc catch least-positive-short-float signal
|
|
195 syn keyword lispFunc ccase least-positive-single-float signed-byte
|
|
196 syn keyword lispFunc cdr length signum
|
|
197 syn keyword lispFunc ceiling let simple-condition
|
|
198 syn keyword lispFunc cell-error let* simple-array
|
|
199 syn keyword lispFunc cell-error-name lisp simple-base-string
|
|
200 syn keyword lispFunc cerror lisp-implementation-type simple-bit-vector
|
|
201 syn keyword lispFunc change-class lisp-implementation-version simple-bit-vector-p
|
|
202 syn keyword lispFunc char list simple-condition-format-arguments
|
|
203 syn keyword lispFunc char-bit list* simple-condition-format-control
|
|
204 syn keyword lispFunc char-bits list-all-packages simple-error
|
|
205 syn keyword lispFunc char-bits-limit list-length simple-string
|
|
206 syn keyword lispFunc char-code listen simple-string-p
|
|
207 syn keyword lispFunc char-code-limit listp simple-type-error
|
|
208 syn keyword lispFunc char-control-bit load simple-vector
|
|
209 syn keyword lispFunc char-downcase load-logical-pathname-translations simple-vector-p
|
|
210 syn keyword lispFunc char-equal load-time-value simple-warning
|
|
211 syn keyword lispFunc char-font locally sin
|
|
212 syn keyword lispFunc char-font-limit log single-flaot-epsilon
|
|
213 syn keyword lispFunc char-greaterp logand single-float
|
|
214 syn keyword lispFunc char-hyper-bit logandc1 single-float-epsilon
|
|
215 syn keyword lispFunc char-int logandc2 single-float-negative-epsilon
|
|
216 syn keyword lispFunc char-lessp logbitp sinh
|
|
217 syn keyword lispFunc char-meta-bit logcount sixth
|
|
218 syn keyword lispFunc char-name logeqv sleep
|
|
219 syn keyword lispFunc char-not-equal logical-pathname slot-boundp
|
|
220 syn keyword lispFunc char-not-greaterp logical-pathname-translations slot-exists-p
|
|
221 syn keyword lispFunc char-not-lessp logior slot-makunbound
|
|
222 syn keyword lispFunc char-super-bit lognand slot-missing
|
|
223 syn keyword lispFunc char-upcase lognor slot-unbound
|
|
224 syn keyword lispFunc char/= lognot slot-value
|
|
225 syn keyword lispFunc char< logorc1 software-type
|
|
226 syn keyword lispFunc char<= logorc2 software-version
|
|
227 syn keyword lispFunc char= logtest some
|
|
228 syn keyword lispFunc char> logxor sort
|
|
229 syn keyword lispFunc char>= long-float space
|
|
230 syn keyword lispFunc character long-float-epsilon special
|
|
231 syn keyword lispFunc characterp long-float-negative-epsilon special-form-p
|
|
232 syn keyword lispFunc check-type long-site-name special-operator-p
|
|
233 syn keyword lispFunc cis loop speed
|
|
234 syn keyword lispFunc class loop-finish sqrt
|
|
235 syn keyword lispFunc class-name lower-case-p stable-sort
|
|
236 syn keyword lispFunc class-of machine-instance standard
|
|
237 syn keyword lispFunc clear-input machine-type standard-char
|
|
238 syn keyword lispFunc clear-output machine-version standard-char-p
|
|
239 syn keyword lispFunc close macro-function standard-class
|
|
240 syn keyword lispFunc clrhash macroexpand standard-generic-function
|
|
241 syn keyword lispFunc code-char macroexpand-1 standard-method
|
|
242 syn keyword lispFunc coerce macroexpand-l standard-object
|
|
243 syn keyword lispFunc commonp macrolet step
|
|
244 syn keyword lispFunc compilation-speed make-array storage-condition
|
|
245 syn keyword lispFunc compile make-array store-value
|
|
246 syn keyword lispFunc compile-file make-broadcast-stream stream
|
|
247 syn keyword lispFunc compile-file-pathname make-char stream-element-type
|
|
248 syn keyword lispFunc compiled-function make-concatenated-stream stream-error
|
|
249 syn keyword lispFunc compiled-function-p make-condition stream-error-stream
|
|
250 syn keyword lispFunc compiler-let make-dispatch-macro-character stream-external-format
|
|
251 syn keyword lispFunc compiler-macro make-echo-stream streamp
|
|
252 syn keyword lispFunc compiler-macro-function make-hash-table streamup
|
|
253 syn keyword lispFunc complement make-instance string
|
|
254 syn keyword lispFunc complex make-instances-obsolete string-capitalize
|
|
255 syn keyword lispFunc complexp make-list string-char
|
|
256 syn keyword lispFunc compute-applicable-methods make-load-form string-char-p
|
|
257 syn keyword lispFunc compute-restarts make-load-form-saving-slots string-downcase
|
|
258 syn keyword lispFunc concatenate make-method string-equal
|
|
259 syn keyword lispFunc concatenated-stream make-package string-greaterp
|
|
260 syn keyword lispFunc concatenated-stream-streams make-pathname string-left-trim
|
|
261 syn keyword lispFunc cond make-random-state string-lessp
|
|
262 syn keyword lispFunc condition make-sequence string-not-equal
|
|
263 syn keyword lispFunc conjugate make-string string-not-greaterp
|
|
264 syn keyword lispFunc cons make-string-input-stream string-not-lessp
|
|
265 syn keyword lispFunc consp make-string-output-stream string-right-strim
|
|
266 syn keyword lispFunc constantly make-symbol string-right-trim
|
|
267 syn keyword lispFunc constantp make-synonym-stream string-stream
|
|
268 syn keyword lispFunc continue make-two-way-stream string-trim
|
|
269 syn keyword lispFunc control-error makunbound string-upcase
|
|
270 syn keyword lispFunc copy-alist map string/=
|
|
271 syn keyword lispFunc copy-list map-into string<
|
|
272 syn keyword lispFunc copy-pprint-dispatch mapc string<=
|
|
273 syn keyword lispFunc copy-readtable mapcan string=
|
|
274 syn keyword lispFunc copy-seq mapcar string>
|
|
275 syn keyword lispFunc copy-structure mapcon string>=
|
|
276 syn keyword lispFunc copy-symbol maphash stringp
|
|
277 syn keyword lispFunc copy-tree mapl structure
|
|
278 syn keyword lispFunc cos maplist structure-class
|
|
279 syn keyword lispFunc cosh mask-field structure-object
|
|
280 syn keyword lispFunc count max style-warning
|
|
281 syn keyword lispFunc count-if member sublim
|
|
282 syn keyword lispFunc count-if-not member-if sublis
|
|
283 syn keyword lispFunc ctypecase member-if-not subseq
|
|
284 syn keyword lispFunc debug merge subsetp
|
|
285 syn keyword lispFunc decf merge-pathname subst
|
|
286 syn keyword lispFunc declaim merge-pathnames subst-if
|
|
287 syn keyword lispFunc declaration method subst-if-not
|
|
288 syn keyword lispFunc declare method-combination substitute
|
|
289 syn keyword lispFunc decode-float method-combination-error substitute-if
|
|
290 syn keyword lispFunc decode-universal-time method-qualifiers substitute-if-not
|
|
291 syn keyword lispFunc defclass min subtypep
|
|
292 syn keyword lispFunc defconstant minusp svref
|
|
293 syn keyword lispFunc defgeneric mismatch sxhash
|
|
294 syn keyword lispFunc define-compiler-macro mod symbol
|
|
295 syn keyword lispFunc define-condition most-negative-double-float symbol-function
|
|
296 syn keyword lispFunc define-method-combination most-negative-fixnum symbol-macrolet
|
|
297 syn keyword lispFunc define-modify-macro most-negative-long-float symbol-name
|
|
298 syn keyword lispFunc define-setf-expander most-negative-short-float symbol-package
|
|
299 syn keyword lispFunc define-setf-method most-negative-single-float symbol-plist
|
|
300 syn keyword lispFunc define-symbol-macro most-positive-double-float symbol-value
|
|
301 syn keyword lispFunc defmacro most-positive-fixnum symbolp
|
|
302 syn keyword lispFunc defmethod most-positive-long-float synonym-stream
|
|
303 syn keyword lispFunc defpackage most-positive-short-float synonym-stream-symbol
|
|
304 syn keyword lispFunc defparameter most-positive-single-float sys
|
|
305 syn keyword lispFunc defsetf muffle-warning system
|
|
306 syn keyword lispFunc defstruct multiple-value-bind t
|
|
307 syn keyword lispFunc deftype multiple-value-call tagbody
|
|
308 syn keyword lispFunc defun multiple-value-list tailp
|
|
309 syn keyword lispFunc defvar multiple-value-prog1 tan
|
|
310 syn keyword lispFunc delete multiple-value-seteq tanh
|
|
311 syn keyword lispFunc delete-duplicates multiple-value-setq tenth
|
|
312 syn keyword lispFunc delete-file multiple-values-limit terpri
|
|
313 syn keyword lispFunc delete-if name-char the
|
|
314 syn keyword lispFunc delete-if-not namestring third
|
|
315 syn keyword lispFunc delete-package nbutlast throw
|
|
316 syn keyword lispFunc denominator nconc time
|
|
317 syn keyword lispFunc deposit-field next-method-p trace
|
|
318 syn keyword lispFunc describe nil translate-logical-pathname
|
|
319 syn keyword lispFunc describe-object nintersection translate-pathname
|
|
320 syn keyword lispFunc destructuring-bind ninth tree-equal
|
|
321 syn keyword lispFunc digit-char no-applicable-method truename
|
|
322 syn keyword lispFunc digit-char-p no-next-method truncase
|
|
323 syn keyword lispFunc directory not truncate
|
|
324 syn keyword lispFunc directory-namestring notany two-way-stream
|
|
325 syn keyword lispFunc disassemble notevery two-way-stream-input-stream
|
|
326 syn keyword lispFunc division-by-zero notinline two-way-stream-output-stream
|
|
327 syn keyword lispFunc do nreconc type
|
|
328 syn keyword lispFunc do* nreverse type-error
|
|
329 syn keyword lispFunc do-all-symbols nset-difference type-error-datum
|
|
330 syn keyword lispFunc do-exeternal-symbols nset-exclusive-or type-error-expected-type
|
|
331 syn keyword lispFunc do-external-symbols nstring type-of
|
|
332 syn keyword lispFunc do-symbols nstring-capitalize typecase
|
|
333 syn keyword lispFunc documentation nstring-downcase typep
|
|
334 syn keyword lispFunc dolist nstring-upcase unbound-slot
|
|
335 syn keyword lispFunc dotimes nsublis unbound-slot-instance
|
|
336 syn keyword lispFunc double-float nsubst unbound-variable
|
|
337 syn keyword lispFunc double-float-epsilon nsubst-if undefined-function
|
|
338 syn keyword lispFunc double-float-negative-epsilon nsubst-if-not unexport
|
|
339 syn keyword lispFunc dpb nsubstitute unintern
|
|
340 syn keyword lispFunc dribble nsubstitute-if union
|
|
341 syn keyword lispFunc dynamic-extent nsubstitute-if-not unless
|
|
342 syn keyword lispFunc ecase nth unread
|
|
343 syn keyword lispFunc echo-stream nth-value unread-char
|
|
344 syn keyword lispFunc echo-stream-input-stream nthcdr unsigned-byte
|
|
345 syn keyword lispFunc echo-stream-output-stream null untrace
|
|
346 syn keyword lispFunc ed number unuse-package
|
|
347 syn keyword lispFunc eighth numberp unwind-protect
|
|
348 syn keyword lispFunc elt numerator update-instance-for-different-class
|
|
349 syn keyword lispFunc encode-universal-time nunion update-instance-for-redefined-class
|
|
350 syn keyword lispFunc end-of-file oddp upgraded-array-element-type
|
|
351 syn keyword lispFunc endp open upgraded-complex-part-type
|
|
352 syn keyword lispFunc enough-namestring open-stream-p upper-case-p
|
|
353 syn keyword lispFunc ensure-directories-exist optimize use-package
|
|
354 syn keyword lispFunc ensure-generic-function or use-value
|
|
355 syn keyword lispFunc eq otherwise user
|
|
356 syn keyword lispFunc eql output-stream-p user-homedir-pathname
|
|
357 syn keyword lispFunc equal package values
|
|
358 syn keyword lispFunc equalp package-error values-list
|
|
359 syn keyword lispFunc error package-error-package vector
|
|
360 syn keyword lispFunc etypecase package-name vector-pop
|
|
361 syn keyword lispFunc eval package-nicknames vector-push
|
|
362 syn keyword lispFunc eval-when package-shadowing-symbols vector-push-extend
|
|
363 syn keyword lispFunc evalhook package-use-list vectorp
|
|
364 syn keyword lispFunc evenp package-used-by-list warn
|
|
365 syn keyword lispFunc every packagep warning
|
|
366 syn keyword lispFunc exp pairlis when
|
|
367 syn keyword lispFunc export parse-error wild-pathname-p
|
|
368 syn keyword lispFunc expt parse-integer with-accessors
|
|
369 syn keyword lispFunc extended-char parse-namestring with-compilation-unit
|
|
370 syn keyword lispFunc fboundp pathname with-condition-restarts
|
|
371 syn keyword lispFunc fceiling pathname-device with-hash-table-iterator
|
|
372 syn keyword lispFunc fdefinition pathname-directory with-input-from-string
|
|
373 syn keyword lispFunc ffloor pathname-host with-open-file
|
|
374 syn keyword lispFunc fifth pathname-match-p with-open-stream
|
|
375 syn keyword lispFunc file-author pathname-name with-output-to-string
|
|
376 syn keyword lispFunc file-error pathname-type with-package-iterator
|
|
377 syn keyword lispFunc file-error-pathname pathname-version with-simple-restart
|
|
378 syn keyword lispFunc file-length pathnamep with-slots
|
|
379 syn keyword lispFunc file-namestring peek-char with-standard-io-syntax
|
|
380 syn keyword lispFunc file-position phase write
|
|
381 syn keyword lispFunc file-stream pi write-byte
|
|
382 syn keyword lispFunc file-string-length plusp write-char
|
|
383 syn keyword lispFunc file-write-date pop write-line
|
|
384 syn keyword lispFunc fill position write-sequence
|
|
385 syn keyword lispFunc fill-pointer position-if write-string
|
|
386 syn keyword lispFunc find position-if-not write-to-string
|
|
387 syn keyword lispFunc find-all-symbols pprint y-or-n-p
|
|
388 syn keyword lispFunc find-class pprint-dispatch yes-or-no-p
|
|
389 syn keyword lispFunc find-if pprint-exit-if-list-exhausted zerop
|
|
390 syn keyword lispFunc find-if-not pprint-fill
|
7
|
391
|
1624
|
392 syn match lispFunc "\<c[ad]\+r\>"
|
|
393 if exists("g:lispsyntax_clisp")
|
|
394 " CLISP FFI:
|
|
395 syn match lispFunc "\<\(ffi:\)\?with-c-\(place\|var\)\>"
|
|
396 syn match lispFunc "\<\(ffi:\)\?with-foreign-\(object\|string\)\>"
|
|
397 syn match lispFunc "\<\(ffi:\)\?default-foreign-\(language\|library\)\>"
|
|
398 syn match lispFunc "\<\([us]_\?\)\?\(element\|deref\|cast\|slot\|validp\)\>"
|
|
399 syn match lispFunc "\<\(ffi:\)\?set-foreign-pointer\>"
|
|
400 syn match lispFunc "\<\(ffi:\)\?allocate-\(deep\|shallow\)\>"
|
|
401 syn match lispFunc "\<\(ffi:\)\?c-lines\>"
|
|
402 syn match lispFunc "\<\(ffi:\)\?foreign-\(value\|free\|variable\|function\|object\)\>"
|
|
403 syn match lispFunc "\<\(ffi:\)\?foreign-address\(-null\|unsigned\)\?\>"
|
|
404 syn match lispFunc "\<\(ffi:\)\?undigned-foreign-address\>"
|
|
405 syn match lispFunc "\<\(ffi:\)\?c-var-\(address\|object\)\>"
|
|
406 syn match lispFunc "\<\(ffi:\)\?typeof\>"
|
|
407 syn match lispFunc "\<\(ffi:\)\?\(bit\)\?sizeof\>"
|
|
408 " CLISP Macros, functions et al:
|
|
409 syn match lispFunc "\<\(ext:\)\?with-collect\>"
|
|
410 syn match lispFunc "\<\(ext:\)\?letf\*\?\>"
|
|
411 syn match lispFunc "\<\(ext:\)\?finalize\>\>"
|
|
412 syn match lispFunc "\<\(ext:\)\?memoized\>"
|
|
413 syn match lispFunc "\<\(ext:\)\?getenv\>"
|
|
414 syn match lispFunc "\<\(ext:\)\?convert-string-\(to\|from\)-bytes\>"
|
|
415 syn match lispFunc "\<\(ext:\)\?ethe\>"
|
|
416 syn match lispFunc "\<\(ext:\)\?with-gensyms\>"
|
|
417 syn match lispFunc "\<\(ext:\)\?open-http\>"
|
|
418 syn match lispFunc "\<\(ext:\)\?string-concat\>"
|
|
419 syn match lispFunc "\<\(ext:\)\?with-http-\(in\|out\)put\>"
|
|
420 syn match lispFunc "\<\(ext:\)\?with-html-output\>"
|
|
421 syn match lispFunc "\<\(ext:\)\?expand-form\>"
|
|
422 syn match lispFunc "\<\(ext:\)\?\(without-\)\?package-lock\>"
|
|
423 syn match lispFunc "\<\(ext:\)\?re-export\>"
|
|
424 syn match lispFunc "\<\(ext:\)\?saveinitmem\>"
|
|
425 syn match lispFunc "\<\(ext:\)\?\(read\|write\)-\(integer\|float\)\>"
|
|
426 syn match lispFunc "\<\(ext:\)\?\(read\|write\)-\(char\|byte\)-sequence\>"
|
|
427 syn match lispFunc "\<\(custom:\)\?\*system-package-list\*\>"
|
|
428 syn match lispFunc "\<\(custom:\)\?\*ansi\*\>"
|
|
429 endif
|
7
|
430
|
557
|
431 " ---------------------------------------------------------------------
|
556
|
432 " Lisp Keywords (modifiers): {{{1
|
1624
|
433 syn keyword lispKey :abort :from-end :overwrite
|
|
434 syn keyword lispKey :adjustable :gensym :predicate
|
|
435 syn keyword lispKey :append :host :preserve-whitespace
|
|
436 syn keyword lispKey :array :if-does-not-exist :pretty
|
|
437 syn keyword lispKey :base :if-exists :print
|
|
438 syn keyword lispKey :case :include :print-function
|
|
439 syn keyword lispKey :circle :index :probe
|
|
440 syn keyword lispKey :conc-name :inherited :radix
|
|
441 syn keyword lispKey :constructor :initial-contents :read-only
|
|
442 syn keyword lispKey :copier :initial-element :rehash-size
|
|
443 syn keyword lispKey :count :initial-offset :rehash-threshold
|
|
444 syn keyword lispKey :create :initial-value :rename
|
|
445 syn keyword lispKey :default :input :rename-and-delete
|
|
446 syn keyword lispKey :defaults :internal :size
|
|
447 syn keyword lispKey :device :io :start
|
|
448 syn keyword lispKey :direction :junk-allowed :start1
|
|
449 syn keyword lispKey :directory :key :start2
|
|
450 syn keyword lispKey :displaced-index-offset :length :stream
|
|
451 syn keyword lispKey :displaced-to :level :supersede
|
|
452 syn keyword lispKey :element-type :name :test
|
|
453 syn keyword lispKey :end :named :test-not
|
|
454 syn keyword lispKey :end1 :new-version :type
|
|
455 syn keyword lispKey :end2 :nicknames :use
|
|
456 syn keyword lispKey :error :output :verbose
|
|
457 syn keyword lispKey :escape :output-file :version
|
|
458 syn keyword lispKey :external
|
|
459 " defpackage arguments
|
|
460 syn keyword lispKey :documentation :shadowing-import-from :modern :export
|
|
461 syn keyword lispKey :case-sensitive :case-inverted :shadow :import-from :intern
|
|
462 " lambda list keywords
|
|
463 syn keyword lispKey &allow-other-keys &aux &body
|
|
464 syn keyword lispKey &environment &key &optional &rest &whole
|
|
465 " make-array argument
|
|
466 syn keyword lispKey :fill-pointer
|
|
467 " readtable-case values
|
|
468 syn keyword lispKey :upcase :downcase :preserve :invert
|
|
469 " eval-when situations
|
|
470 syn keyword lispKey :load-toplevel :compile-toplevel :execute
|
|
471 " ANSI Extended LOOP:
|
|
472 syn keyword lispKey :while :until :for :do :if :then :else :when :unless :in
|
|
473 syn keyword lispKey :across :finally :collect :nconc :maximize :minimize :sum
|
|
474 syn keyword lispKey :and :with :initially :append :into :count :end :repeat
|
|
475 syn keyword lispKey :always :never :thereis :from :to :upto :downto :below
|
|
476 syn keyword lispKey :above :by :on :being :each :the :hash-key :hash-keys
|
|
477 syn keyword lispKey :hash-value :hash-values :using :of-type :upfrom :downfrom
|
|
478 if exists("g:lispsyntax_clisp")
|
|
479 " CLISP FFI:
|
|
480 syn keyword lispKey :arguments :return-type :library :full :malloc-free
|
|
481 syn keyword lispKey :none :alloca :in :out :in-out :stdc-stdcall :stdc :c
|
|
482 syn keyword lispKey :language :built-in :typedef :external
|
|
483 syn keyword lispKey :fini :init-once :init-always
|
|
484 endif
|
7
|
485
|
557
|
486 " ---------------------------------------------------------------------
|
556
|
487 " Standard Lisp Variables: {{{1
|
1624
|
488 syn keyword lispVar *applyhook* *load-pathname* *print-pprint-dispatch*
|
|
489 syn keyword lispVar *break-on-signals* *load-print* *print-pprint-dispatch*
|
|
490 syn keyword lispVar *break-on-signals* *load-truename* *print-pretty*
|
|
491 syn keyword lispVar *break-on-warnings* *load-verbose* *print-radix*
|
|
492 syn keyword lispVar *compile-file-pathname* *macroexpand-hook* *print-readably*
|
|
493 syn keyword lispVar *compile-file-pathname* *modules* *print-right-margin*
|
|
494 syn keyword lispVar *compile-file-truename* *package* *print-right-margin*
|
|
495 syn keyword lispVar *compile-file-truename* *print-array* *query-io*
|
|
496 syn keyword lispVar *compile-print* *print-base* *random-state*
|
|
497 syn keyword lispVar *compile-verbose* *print-case* *read-base*
|
|
498 syn keyword lispVar *compile-verbose* *print-circle* *read-default-float-format*
|
|
499 syn keyword lispVar *debug-io* *print-escape* *read-eval*
|
|
500 syn keyword lispVar *debugger-hook* *print-gensym* *read-suppress*
|
|
501 syn keyword lispVar *default-pathname-defaults* *print-length* *readtable*
|
|
502 syn keyword lispVar *error-output* *print-level* *standard-input*
|
|
503 syn keyword lispVar *evalhook* *print-lines* *standard-output*
|
|
504 syn keyword lispVar *features* *print-miser-width* *terminal-io*
|
|
505 syn keyword lispVar *gensym-counter* *print-miser-width* *trace-output*
|
7
|
506
|
557
|
507 " ---------------------------------------------------------------------
|
556
|
508 " Strings: {{{1
|
1624
|
509 syn region lispString start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=@Spell
|
556
|
510 if exists("g:lisp_instring")
|
1624
|
511 syn region lispInString keepend matchgroup=Delimiter start=+"(+rs=s+1 skip=+|.\{-}|+ matchgroup=Delimiter end=+)"+ contains=@lispBaseListCluster,lispInStringString
|
|
512 syn region lispInStringString start=+\\"+ skip=+\\\\+ end=+\\"+ contained
|
7
|
513 endif
|
|
514
|
557
|
515 " ---------------------------------------------------------------------
|
556
|
516 " Shared with Xlisp, Declarations, Macros, Functions: {{{1
|
1624
|
517 syn keyword lispDecl defmacro do-all-symbols labels
|
|
518 syn keyword lispDecl defsetf do-external-symbols let
|
|
519 syn keyword lispDecl deftype do-symbols locally
|
|
520 syn keyword lispDecl defun dotimes macrolet
|
|
521 syn keyword lispDecl do* flet multiple-value-bind
|
|
522 if exists("g:lispsyntax_clisp")
|
|
523 " CLISP FFI:
|
|
524 syn match lispDecl "\<\(ffi:\)\?def-c-\(var\|const\|enum\|type\|struct\)\>"
|
|
525 syn match lispDecl "\<\(ffi:\)\?def-call-\(out\|in\)\>"
|
|
526 syn match lispDecl "\<\(ffi:\)\?c-\(function\|struct\|pointer\|string\)\>"
|
|
527 syn match lispDecl "\<\(ffi:\)\?c-ptr\(-null\)\?\>"
|
|
528 syn match lispDecl "\<\(ffi:\)\?c-array\(-ptr\|-max\)\?\>"
|
|
529 syn match lispDecl "\<\(ffi:\)\?[us]\?\(char\|short\|int\|long\)\>"
|
|
530 syn match lispDecl "\<\(win32:\|w32\)\?d\?word\>"
|
|
531 syn match lispDecl "\<\([us]_\?\)\?int\(8\|16\|32\|64\)\(_t\)\?\>"
|
|
532 syn keyword lispDecl size_t off_t time_t handle
|
|
533 endif
|
7
|
534
|
557
|
535 " ---------------------------------------------------------------------
|
556
|
536 " Numbers: supporting integers and floating point numbers {{{1
|
2034
|
537 syn match lispNumber "-\=\(\.\d\+\|\d\+\(\.\d*\)\=\)\([dDeEfFlL][-+]\=\d\+\)\="
|
|
538 syn match lispNumber "-\=\(\d\+/\d\+\)"
|
7
|
539
|
2662
|
540 syn match lispEscapeSpecial "\*\w[a-z_0-9-]*\*"
|
|
541 syn match lispEscapeSpecial !#|[^()'`,"; \t]\+|#!
|
|
542 syn match lispEscapeSpecial !#x\x\+!
|
|
543 syn match lispEscapeSpecial !#o\o\+!
|
|
544 syn match lispEscapeSpecial !#b[01]\+!
|
|
545 syn match lispEscapeSpecial !#\\[ -}\~]!
|
|
546 syn match lispEscapeSpecial !#[':][^()'`,"; \t]\+!
|
|
547 syn match lispEscapeSpecial !#([^()'`,"; \t]\+)!
|
|
548 syn match lispEscapeSpecial !#\\\%(Space\|Newline\|Tab\|Page\|Rubout\|Linefeed\|Return\|Backspace\)!
|
|
549 syn match lispEscapeSpecial "\<+[a-zA-Z_][a-zA-Z_0-9-]*+\>"
|
7
|
550
|
1624
|
551 syn match lispConcat "\s\.\s"
|
|
552 syn match lispParenError ")"
|
7
|
553
|
557
|
554 " ---------------------------------------------------------------------
|
556
|
555 " Comments: {{{1
|
1624
|
556 syn cluster lispCommentGroup contains=lispTodo,@Spell
|
|
557 syn match lispComment ";.*$" contains=@lispCommentGroup
|
|
558 syn region lispCommentRegion start="#|" end="|#" contains=lispCommentRegion,@lispCommentGroup
|
|
559 syn keyword lispTodo contained combak combak: todo todo:
|
7
|
560
|
557
|
561 " ---------------------------------------------------------------------
|
556
|
562 " Synchronization: {{{1
|
7
|
563 syn sync lines=100
|
|
564
|
557
|
565 " ---------------------------------------------------------------------
|
556
|
566 " Define Highlighting: {{{1
|
7
|
567 " For version 5.7 and earlier: only when not done already
|
|
568 " For version 5.8 and later: only when an item doesn't have highlighting yet
|
557
|
569 if version >= 508
|
|
570 command -nargs=+ HiLink hi def link <args>
|
7
|
571
|
1624
|
572 HiLink lispCommentRegion lispComment
|
|
573 HiLink lispAtomNmbr lispNumber
|
|
574 HiLink lispAtomMark lispMark
|
|
575 HiLink lispInStringString lispString
|
7
|
576
|
1624
|
577 HiLink lispAtom Identifier
|
|
578 HiLink lispAtomBarSymbol Special
|
|
579 HiLink lispBarSymbol Special
|
|
580 HiLink lispComment Comment
|
|
581 HiLink lispConcat Statement
|
|
582 HiLink lispDecl Statement
|
|
583 HiLink lispFunc Statement
|
|
584 HiLink lispKey Type
|
|
585 HiLink lispMark Delimiter
|
|
586 HiLink lispNumber Number
|
|
587 HiLink lispParenError Error
|
2662
|
588 HiLink lispEscapeSpecial Type
|
1624
|
589 HiLink lispString String
|
|
590 HiLink lispTodo Todo
|
|
591 HiLink lispVar Statement
|
7
|
592
|
556
|
593 if exists("g:lisp_rainbow") && g:lisp_rainbow != 0
|
|
594 if &bg == "dark"
|
557
|
595 hi def hlLevel0 ctermfg=red guifg=red1
|
1624
|
596 hi def hlLevel1 ctermfg=yellow guifg=orange1
|
|
597 hi def hlLevel2 ctermfg=green guifg=yellow1
|
|
598 hi def hlLevel3 ctermfg=cyan guifg=greenyellow
|
|
599 hi def hlLevel4 ctermfg=magenta guifg=green1
|
|
600 hi def hlLevel5 ctermfg=red guifg=springgreen1
|
|
601 hi def hlLevel6 ctermfg=yellow guifg=cyan1
|
|
602 hi def hlLevel7 ctermfg=green guifg=slateblue1
|
|
603 hi def hlLevel8 ctermfg=cyan guifg=magenta1
|
557
|
604 hi def hlLevel9 ctermfg=magenta guifg=purple1
|
556
|
605 else
|
557
|
606 hi def hlLevel0 ctermfg=red guifg=red3
|
|
607 hi def hlLevel1 ctermfg=darkyellow guifg=orangered3
|
|
608 hi def hlLevel2 ctermfg=darkgreen guifg=orange2
|
|
609 hi def hlLevel3 ctermfg=blue guifg=yellow3
|
|
610 hi def hlLevel4 ctermfg=darkmagenta guifg=olivedrab4
|
|
611 hi def hlLevel5 ctermfg=red guifg=green4
|
|
612 hi def hlLevel6 ctermfg=darkyellow guifg=paleturquoise3
|
|
613 hi def hlLevel7 ctermfg=darkgreen guifg=deepskyblue4
|
|
614 hi def hlLevel8 ctermfg=blue guifg=darkslateblue
|
|
615 hi def hlLevel9 ctermfg=darkmagenta guifg=darkviolet
|
556
|
616 endif
|
|
617 endif
|
|
618
|
7
|
619 delcommand HiLink
|
|
620 endif
|
|
621
|
|
622 let b:current_syntax = "lisp"
|
|
623
|
557
|
624 " ---------------------------------------------------------------------
|
556
|
625 " vim: ts=8 nowrap fdm=marker
|