" VIM Syntax file for txr " Kaz Kylheku " INSTALL-HOWTO: " " 1. Create the directory .vim/syntax in your home directory and " put the files txr.vim and txl.vim into this directory. " 2. In your .vimrc, add this command to associate *.txr and *.tl " files with the txr and txl filetypes: " :au BufRead,BufNewFile *.txr set filetype=txr | set lisp " :au BufRead,BufNewFile *.tl set filetype=txl | set lisp " " If you want syntax highlighting to be on automatically (for any language) " you need to add ":syntax on" in your .vimrc also. But you knew that already! " " This file is generated by the genvim.txr script in the TXR source tree. syn case match syn spell toplevel setlocal iskeyword=a-z,A-Z,48-57,!,$,&,*,+,-,<,=,>,?,\\,_,~,/ syn keyword txl_keyword contained * *args* *e* *flo-dig* syn keyword txl_keyword contained *flo-epsilon* *flo-max* *flo-min* *full-args* syn keyword txl_keyword contained *gensym-counter* *keyword-package* *pi* *random-state* syn keyword txl_keyword contained *self-path* *stddebug* *stderr* *stdin* syn keyword txl_keyword contained *stdlog* *stdnull* *stdout* *txr-version* syn keyword txl_keyword contained *user-package* + - / syn keyword txl_keyword contained /= < <= = syn keyword txl_keyword contained > >= abs abs-path-p syn keyword txl_keyword contained acons acons-new aconsql-new acos syn keyword txl_keyword contained ado alist-nremove alist-remove all syn keyword txl_keyword contained and andf ap apf syn keyword txl_keyword contained append append* append-each append-each* syn keyword txl_keyword contained apply aret ash asin syn keyword txl_keyword contained assoc assql atan atan2 syn keyword txl_keyword contained atom bignump bit block syn keyword txl_keyword contained boundp break-str call car syn keyword txl_keyword contained caseq caseql casequal cat-str syn keyword txl_keyword contained cat-streams cat-vec catch cdr syn keyword txl_keyword contained ceil chain chand chdir syn keyword txl_keyword contained chr-isalnum chr-isalpha chr-isascii chr-isblank syn keyword txl_keyword contained chr-iscntrl chr-isdigit chr-isgraph chr-islower syn keyword txl_keyword contained chr-isprint chr-ispunct chr-isspace chr-isunisp syn keyword txl_keyword contained chr-isupper chr-isxdigit chr-num chr-str syn keyword txl_keyword contained chr-str-set chr-tolower chr-toupper chrp syn keyword txl_keyword contained close-stream closelog cmp-str collect-each syn keyword txl_keyword contained collect-each* comb compl-span-str cond syn keyword txl_keyword contained cons conses conses* consp syn keyword txl_keyword contained constantp copy copy-alist copy-cons syn keyword txl_keyword contained copy-hash copy-list copy-str copy-vec syn keyword txl_keyword contained cos count-if countq countql syn keyword txl_keyword contained countqual cum-norm-dist daemon dec syn keyword txl_keyword contained defmacro defsymacro defun defvar syn keyword txl_keyword contained del delay delete-package do syn keyword txl_keyword contained dohash downcase-str dwim each syn keyword txl_keyword contained each* empty env env-fbind syn keyword txl_keyword contained env-hash env-vbind eq eql syn keyword txl_keyword contained equal errno error eval syn keyword txl_keyword contained evenp exit exp expt syn keyword txl_keyword contained exptmod false fbind fboundp syn keyword txl_keyword contained fifth filter-equal filter-string-tree finalize syn keyword txl_keyword contained find find-if find-max find-min syn keyword txl_keyword contained find-package first fixnump flatten syn keyword txl_keyword contained flatten* flet flip flo-int syn keyword txl_keyword contained flo-str floatp floor flush-stream syn keyword txl_keyword contained for for* force format syn keyword txl_keyword contained fourth fun func-get-env func-get-form syn keyword txl_keyword contained func-set-env functionp gcd gen syn keyword txl_keyword contained generate gensym gequal get-byte syn keyword txl_keyword contained get-char get-hash-userdata get-line get-lines syn keyword txl_keyword contained get-list-from-stream get-sig-handler get-string get-string-from-stream syn keyword txl_keyword contained gethash getitimer getpid getppid syn keyword txl_keyword contained giterate glob glob-altdirfunc glob-brace syn keyword txl_keyword contained glob-err glob-mark glob-nocheck glob-noescape syn keyword txl_keyword contained glob-nomagic glob-nosort glob-onlydir glob-period syn keyword txl_keyword contained glob-tilde glob-tilde-check greater group-by syn keyword txl_keyword contained gun hash hash-alist hash-construct syn keyword txl_keyword contained hash-count hash-diff hash-eql hash-equal syn keyword txl_keyword contained hash-isec hash-keys hash-pairs hash-uni syn keyword txl_keyword contained hash-update hash-update-1 hash-values hashp syn keyword txl_keyword contained html-decode html-encode iapply identity syn keyword txl_keyword contained ido if iff iffi syn keyword txl_keyword contained in inc inhash int-flo syn keyword txl_keyword contained int-str integerp intern interp-fun-p syn keyword txl_keyword contained interpose ip ipf isqrt syn keyword txl_keyword contained itimer-prov itimer-real itimer-virtual juxt syn keyword txl_keyword contained keep-if keep-if* keywordp kill syn keyword txl_keyword contained labels lambda last lazy-str syn keyword txl_keyword contained lazy-str-force lazy-str-force-upto lazy-str-get-trailing-list lazy-stream-cons syn keyword txl_keyword contained lazy-stringp lbind lcm lcons-fun syn keyword txl_keyword contained lconsp ldiff length length-list syn keyword txl_keyword contained length-str length-str-< length-str-<= length-str-> syn keyword txl_keyword contained length-str->= length-vec lequal less syn keyword txl_keyword contained let let* lexical-fun-p lexical-var-p syn keyword txl_keyword contained link lisp-parse list list* syn keyword txl_keyword contained list-str list-vector listp log syn keyword txl_keyword contained log-alert log-auth log-authpriv log-cons syn keyword txl_keyword contained log-crit log-daemon log-debug log-emerg syn keyword txl_keyword contained log-err log-info log-ndelay log-notice syn keyword txl_keyword contained log-nowait log-odelay log-perror log-pid syn keyword txl_keyword contained log-user log-warning log10 log2 syn keyword txl_keyword contained logand logior lognot logtest syn keyword txl_keyword contained logtrunc logxor macro-form-p macro-time syn keyword txl_keyword contained macroexpand macroexpand-1 macrolet major syn keyword txl_keyword contained make-catenated-stream make-env make-hash make-lazy-cons syn keyword txl_keyword contained make-like make-package make-random-state make-similar-hash syn keyword txl_keyword contained make-string-byte-input-stream make-string-input-stream make-string-output-stream make-strlist-output-stream syn keyword txl_keyword contained make-sym make-time make-time-utc make-trie syn keyword txl_keyword contained makedev mapcar mapcar* mapdo syn keyword txl_keyword contained maphash mappend mappend* mask syn keyword txl_keyword contained match-fun match-regex match-regex-right match-str syn keyword txl_keyword contained match-str-tree max member member-if syn keyword txl_keyword contained memq memql memqual merge syn keyword txl_keyword contained min minor minusp mkdir syn keyword txl_keyword contained mknod mkstring mod multi syn keyword txl_keyword contained multi-sort n-choose-k n-perm-k nconc syn keyword txl_keyword contained nilf none not notf syn keyword txl_keyword contained nreverse null nullify num-chr syn keyword txl_keyword contained num-str numberp oand oddp syn keyword txl_keyword contained op open-command open-directory open-file syn keyword txl_keyword contained open-files open-files* open-pipe open-process syn keyword txl_keyword contained open-tail openlog opip or syn keyword txl_keyword contained orf packagep partition partition* syn keyword txl_keyword contained partition-by perm plusp pop syn keyword txl_keyword contained pos pos-if pos-max pos-min syn keyword txl_keyword contained posq posql posqual pppred syn keyword txl_keyword contained ppred pprinl pprint pprof syn keyword txl_keyword contained pred prinl print prof syn keyword txl_keyword contained prog1 progn prop proper-listp syn keyword txl_keyword contained push pushhash put-byte put-char syn keyword txl_keyword contained put-line put-lines put-string put-strings syn keyword txl_keyword contained pwd qquote quasi quasilist syn keyword txl_keyword contained quote rand random random-fixnum syn keyword txl_keyword contained random-state-p range range* range-regex syn keyword txl_keyword contained rcomb read readlink real-time-stream-p syn keyword txl_keyword contained reduce-left reduce-right ref refset syn keyword txl_keyword contained regex-compile regex-parse regexp regsub syn keyword txl_keyword contained rehome-sym remhash remove-if remove-if* syn keyword txl_keyword contained remove-path remq remq* remql syn keyword txl_keyword contained remql* remqual remqual* rename-path syn keyword txl_keyword contained repeat replace replace-list replace-str syn keyword txl_keyword contained replace-vec rest ret retf syn keyword txl_keyword contained return return-from reverse rlcp syn keyword txl_keyword contained rperm rplaca rplacd run syn keyword txl_keyword contained s-ifblk s-ifchr s-ifdir s-ififo syn keyword txl_keyword contained s-iflnk s-ifmt s-ifreg s-ifsock syn keyword txl_keyword contained s-irgrp s-iroth s-irusr s-irwxg syn keyword txl_keyword contained s-irwxo s-irwxu s-isgid s-isuid syn keyword txl_keyword contained s-isvtx s-iwgrp s-iwoth s-iwusr syn keyword txl_keyword contained s-ixgrp s-ixoth s-ixusr search syn keyword txl_keyword contained search-regex search-str search-str-tree second syn keyword txl_keyword contained seek-stream select seqp set syn keyword txl_keyword contained set-diff set-hash-userdata set-sig-handler sethash syn keyword txl_keyword contained setitimer setlogmask sh sig-abrt syn keyword txl_keyword contained sig-alrm sig-bus sig-check sig-chld syn keyword txl_keyword contained sig-cont sig-fpe sig-hup sig-ill syn keyword txl_keyword contained sig-int sig-io sig-iot sig-kill syn keyword txl_keyword contained sig-lost sig-pipe sig-poll sig-prof syn keyword txl_keyword contained sig-pwr sig-quit sig-segv sig-stkflt syn keyword txl_keyword contained sig-stop sig-sys sig-term sig-trap syn keyword txl_keyword contained sig-tstp sig-ttin sig-ttou sig-urg syn keyword txl_keyword contained sig-usr1 sig-usr2 sig-vtalrm sig-winch syn keyword txl_keyword contained sig-xcpu sig-xfsz sin sixth syn keyword txl_keyword contained size-vec some sort sort-group syn keyword txl_keyword contained source-loc source-loc-str span-str splice syn keyword txl_keyword contained split-str split-str-set sqrt sssucc syn keyword txl_keyword contained ssucc stat stdlib str< syn keyword txl_keyword contained str<= str= str> str>= syn keyword txl_keyword contained stream-get-prop stream-set-prop streamp string-extend syn keyword txl_keyword contained string-lt stringp sub sub-list syn keyword txl_keyword contained sub-str sub-vec succ symacrolet syn keyword txl_keyword contained symbol-function symbol-name symbol-package symbol-value syn keyword txl_keyword contained symbolp symlink sys-qquote sys-splice syn keyword txl_keyword contained sys-unquote syslog tan tb syn keyword txl_keyword contained tc tf third throw syn keyword txl_keyword contained throwf time time-fields-local time-fields-utc syn keyword txl_keyword contained time-string-local time-string-utc time-usec tofloat syn keyword txl_keyword contained toint tok-str tok-where tostring syn keyword txl_keyword contained tostringp transpose tree-bind tree-case syn keyword txl_keyword contained tree-find trie-add trie-compress trie-lookup-begin syn keyword txl_keyword contained trie-lookup-feed-char trie-value-at trim-str true syn keyword txl_keyword contained trunc tuples txr-case txr-if syn keyword txl_keyword contained txr-when typeof unget-byte unget-char syn keyword txl_keyword contained uniq unique unless unquote syn keyword txl_keyword contained until upcase-str update url-decode syn keyword txl_keyword contained url-encode usleep uw-protect vec syn keyword txl_keyword contained vec-push vec-set-length vecref vector syn keyword txl_keyword contained vector-list vectorp when where syn keyword txl_keyword contained while with-saved-vars wrap wrap* syn keyword txl_keyword contained zerop zip syn match txr_metanum "@[0-9]\+" syn match txr_nested_error "[^\t `]\+" contained syn match txr_chr "#\\x[A-Fa-f0-9]\+" syn match txr_chr "#\\o[0-9]\+" syn match txr_chr "#\\[^ \t\nA-Za-z0-9_]" syn match txr_chr "#\\[A-Za-z0-9_]\+" syn match txr_ncomment ";.*" syn match txr_dot "\." contained syn match txr_num "#x[+\-]\?[0-9A-Fa-f]\+" syn match txr_num "#o[+\-]\?[0-7]\+" syn match txr_num "#b[+\-]\?[0-1]\+" syn match txr_ident "[A-Za-z0-9!$%&*+\-<=>?\\_~]*[A-Za-z!$#%&*+\-<=>?\\^_~][A-Za-z0-9!$#%&*+\-<=>?\\^_~]*" contained syn match txl_ident "[:@][A-Za-z0-9!$%&*+\-<=>?\\\^_~/]\+" syn match txr_braced_ident "[:][A-Za-z0-9!$%&*+\-<=>?\\\^_~/]\+" contained syn match txl_ident "[A-Za-z0-9!$%&*+\-<=>?\\_~/]*[A-Za-z!$#%&*+\-<=>?\\^_~/][A-Za-z0-9!$#%&*+\-<=>?\\^_~/]*" syn match txr_num "[+\-]\?[0-9]\+\([^A-Za-z0-9!$#%&*+\-<=>?\\^_~/]\|\n\)"me=e-1 syn match txr_badnum "[+\-]\?[0-9]*[.][0-9]\+\([eE][+\-]\?[0-9]\+\)\?[A-Za-z!$#%&*+\-<=>?\\^_~/]\+" syn match txr_num "[+\-]\?[0-9]*[.][0-9]\+\([eE][+\-]\?[0-9]\+\)\?\([^A-Za-z0-9!$#%&*+\-<=>?\\^_~/]\|\n\)"me=e-1 syn match txr_num "[+\-]\?[0-9]\+\([eE][+\-]\?[0-9]\+\)\([^A-Za-z0-9!$#%&*+\-<=>?\\^_~/]\|\n\)"me=e-1 syn match txl_ident ":" syn match txl_splice "[ \t,]\|,[*]" syn match txr_unquote "," contained syn match txr_splice ",\*" contained syn match txr_quote "'" contained syn match txr_quote "\^" contained syn match txr_dotdot "\.\." contained syn match txr_metaat "@" contained syn region txr_list matchgroup=Delimiter start="#\?H\?(" matchgroup=Delimiter end=")" contains=txl_keyword,txr_string,txl_regex,txr_num,txr_badnum,txl_ident,txr_metanum,txr_list,txr_bracket,txr_mlist,txr_mbracket,txr_quasilit,txr_chr,txr_quote,txr_unquote,txr_splice,txr_dot,txr_dotdot,txr_metaat,txr_ncomment,txr_nested_error syn region txr_bracket matchgroup=Delimiter start="\[" matchgroup=Delimiter end="\]" contains=txl_keyword,txr_string,txl_regex,txr_num,txr_badnum,txl_ident,txr_metanum,txr_list,txr_bracket,txr_mlist,txr_mbracket,txr_quasilit,txr_chr,txr_quote,txr_unquote,txr_splice,txr_dot,txr_dotdot,txr_metaat,txr_ncomment,txr_nested_error syn region txr_mlist matchgroup=Delimiter start="@[ \t]*(" matchgroup=Delimiter end=")" contains=txl_keyword,txr_string,txl_regex,txr_num,txr_badnum,txl_ident,txr_metanum,txr_list,txr_bracket,txr_mlist,txr_mbracket,txr_quasilit,txr_chr,txr_quote,txr_unquote,txr_splice,txr_dot,txr_dotdot,txr_metaat,txr_ncomment,txr_nested_error syn region txr_mbracket matchgroup=Delimiter start="@[ \t]*\[" matchgroup=Delimiter end="\]" contains=txl_keyword,txr_string,txl_regex,txr_num,txr_badnum,txl_ident,txr_metanum,txr_list,txr_bracket,txr_mlist,txr_mbracket,txr_quasilit,txr_chr,txr_quote,txr_unquote,txr_splice,txr_dot,txr_dotdot,txr_metaat,txr_ncomment,txr_nested_error syn region txr_string start=+#\?\*\?"+ skip=+\\\\\|\\"\|\\\n+ end=+"\|\n+ syn region txr_quasilit start=+#\?\*\?`+ skip=+\\\\\|\\`\|\\\n+ end=+`\|\n+ contains=txr_splicevar,txr_metanum,txr_bracevar,txr_mlist,txr_mbracket syn region txr_regex start="/" skip="\\\\\|\\/\|\\\n" end="/\|\n" syn region txl_regex start="#/" skip="\\\\\|\\/\|\\\n" end="/\|\n" hi def link txr_at Special hi def link txr_atstar Special hi def link txr_atat Special hi def link txr_comment Comment hi def link txr_ncomment Comment hi def link txr_hashbang Preproc hi def link txr_contin Preproc hi def link txr_char String hi def link txr_keyword Keyword hi def link txl_keyword Type hi def link txr_string String hi def link txr_chr String hi def link txr_quasilit String hi def link txr_regex String hi def link txl_regex String hi def link txr_regdir String hi def link txr_variable Identifier hi def link txr_splicevar Identifier hi def link txr_metanum Identifier hi def link txr_ident Identifier hi def link txl_ident Identifier hi def link txr_num Number hi def link txr_badnum Error hi def link txr_quote Special hi def link txr_unquote Special hi def link txr_splice Special hi def link txr_dot Special hi def link txr_dotdot Special hi def link txr_metaat Special hi def link txr_munqspl Special hi def link txl_splice Special hi def link txr_error Error hi def link txr_nested_error Error let b:current_syntax = "lisp"