" 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 *unhandled-hook* *user-package* + - syn keyword txl_keyword contained / /= < <= syn keyword txl_keyword contained = > >= abort syn keyword txl_keyword contained abs abs-path-p acons acons-new syn keyword txl_keyword contained aconsql-new acos ado alist-nremove syn keyword txl_keyword contained alist-remove all and andf syn keyword txl_keyword contained ap apf append append* syn keyword txl_keyword contained append-each append-each* apply aret syn keyword txl_keyword contained ash asin assoc assql syn keyword txl_keyword contained atan atan2 atom bignump syn keyword txl_keyword contained bit block boundp break-str syn keyword txl_keyword contained call callf car caseq syn keyword txl_keyword contained caseql casequal cat-str cat-streams syn keyword txl_keyword contained cat-vec catch cdr ceil syn keyword txl_keyword contained chain chand chdir chmod 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 clear-error close-stream closelog cmp-str syn keyword txl_keyword contained collect-each collect-each* comb compl-span-str syn keyword txl_keyword contained cond cons conses conses* syn keyword txl_keyword contained consp constantp copy copy-alist syn keyword txl_keyword contained copy-cons copy-hash copy-list copy-str syn keyword txl_keyword contained copy-vec cos count-if countq syn keyword txl_keyword contained countql countqual cum-norm-dist daemon syn keyword txl_keyword contained dec defmacro defsymacro defun syn keyword txl_keyword contained defvar del delay delete-package syn keyword txl_keyword contained do dohash dotimes downcase-str syn keyword txl_keyword contained dup dupfd dwim each syn keyword txl_keyword contained each* empty ensure-dir env syn keyword txl_keyword contained env-fbind env-hash env-vbind eq syn keyword txl_keyword contained eql equal errno error syn keyword txl_keyword contained eval evenp exec exit syn keyword txl_keyword contained exp expt exptmod false syn keyword txl_keyword contained fbind fboundp fifth fileno syn keyword txl_keyword contained filter-equal filter-string-tree finalize find syn keyword txl_keyword contained find-if find-max find-min find-package syn keyword txl_keyword contained first fixnump flatten flatten* syn keyword txl_keyword contained flet flip flo-int flo-str syn keyword txl_keyword contained floatp floor flush-stream for syn keyword txl_keyword contained for* force fork 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-error get-error-str get-hash-userdata syn keyword txl_keyword contained get-line get-lines get-list-from-stream get-sig-handler syn keyword txl_keyword contained get-string get-string-from-stream gethash getitimer syn keyword txl_keyword contained getpid getppid giterate glob syn keyword txl_keyword contained glob-altdirfunc glob-brace glob-err glob-mark syn keyword txl_keyword contained glob-nocheck glob-noescape glob-nomagic glob-nosort syn keyword txl_keyword contained glob-onlydir glob-period glob-tilde glob-tilde-check syn keyword txl_keyword contained greater group-by gun hash syn keyword txl_keyword contained hash-alist hash-construct hash-count hash-diff syn keyword txl_keyword contained hash-eql hash-equal hash-isec hash-keys syn keyword txl_keyword contained hash-pairs hash-uni hash-update hash-update-1 syn keyword txl_keyword contained hash-values hashp html-decode html-encode syn keyword txl_keyword contained iapply identity ido if syn keyword txl_keyword contained iff iffi iflet ignerr 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-lisp1-binding syn keyword txl_keyword contained lexical-var-p link lisp-parse list syn keyword txl_keyword contained list* list-str list-vector listp syn keyword txl_keyword contained log log-alert log-auth log-authpriv syn keyword txl_keyword contained log-cons log-crit log-daemon log-debug syn keyword txl_keyword contained log-emerg log-err log-info log-ndelay syn keyword txl_keyword contained log-notice log-nowait log-odelay log-perror syn keyword txl_keyword contained log-pid log-user log-warning log10 syn keyword txl_keyword contained log2 logand logior lognot syn keyword txl_keyword contained logtest logtrunc logxor macro-form-p syn keyword txl_keyword contained macro-time macroexpand macroexpand-1 macrolet syn keyword txl_keyword contained major make-catenated-stream make-env make-hash syn keyword txl_keyword contained make-lazy-cons make-like make-package make-random-state syn keyword txl_keyword contained make-similar-hash make-string-byte-input-stream make-string-input-stream make-string-output-stream syn keyword txl_keyword contained make-strlist-output-stream make-sym make-time make-time-utc syn keyword txl_keyword contained make-trie makedev mapcar mapcar* syn keyword txl_keyword contained mapdo mapf maphash mappend syn keyword txl_keyword contained mappend* mask match-fun match-regex syn keyword txl_keyword contained match-regex-right match-regst match-regst-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-fileno open-files open-files* open-pipe syn keyword txl_keyword contained open-process open-tail openlog opip syn keyword txl_keyword contained or orf packagep pad syn keyword txl_keyword contained partition partition* partition-by perm syn keyword txl_keyword contained pipe plusp pop pos syn keyword txl_keyword contained pos-if pos-max pos-min posq syn keyword txl_keyword contained posql posqual pppred ppred syn keyword txl_keyword contained pprinl pprint pprof pred syn keyword txl_keyword contained prinl print prof prog1 syn keyword txl_keyword contained progn prop proper-listp push syn keyword txl_keyword contained pushhash put-byte put-char put-line syn keyword txl_keyword contained put-lines put-string put-strings pwd syn keyword txl_keyword contained qquote quasi quasilist quote syn keyword txl_keyword contained rand random random-fixnum random-state-p syn keyword txl_keyword contained range range* range-regex rcomb syn keyword txl_keyword contained read readlink real-time-stream-p reduce-left syn keyword txl_keyword contained reduce-right ref refset regex-compile syn keyword txl_keyword contained regex-parse regexp regsub rehome-sym syn keyword txl_keyword contained remhash remove-if remove-if* remove-path syn keyword txl_keyword contained remq remq* remql remql* syn keyword txl_keyword contained remqual remqual* rename-path repeat syn keyword txl_keyword contained replace replace-list replace-str replace-vec syn keyword txl_keyword contained rest ret retf return syn keyword txl_keyword contained return-from reverse rlcp rperm syn keyword txl_keyword contained rplaca rplacd run s-ifblk syn keyword txl_keyword contained s-ifchr s-ifdir s-ififo s-iflnk syn keyword txl_keyword contained s-ifmt s-ifreg s-ifsock s-irgrp syn keyword txl_keyword contained s-iroth s-irusr s-irwxg s-irwxo syn keyword txl_keyword contained s-irwxu s-isgid s-isuid s-isvtx syn keyword txl_keyword contained s-iwgrp s-iwoth s-iwusr s-ixgrp syn keyword txl_keyword contained s-ixoth s-ixusr search search-regex syn keyword txl_keyword contained search-regst 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 sign-extend sin syn keyword txl_keyword contained sixth size-vec some sort syn keyword txl_keyword contained sort-group source-loc source-loc-str span-str syn keyword txl_keyword contained splice split-str split-str-set sqrt syn keyword txl_keyword contained sssucc ssucc stat stdlib syn keyword txl_keyword contained str< str<= str= str> syn keyword txl_keyword contained str>= stream-get-prop stream-set-prop streamp syn keyword txl_keyword contained string-extend string-lt stringp sub syn keyword txl_keyword contained sub-list sub-str sub-vec succ syn keyword txl_keyword contained symacrolet symbol-function symbol-name symbol-package syn keyword txl_keyword contained symbol-value symbolp symlink sys-qquote syn keyword txl_keyword contained sys-splice sys-unquote syslog tan syn keyword txl_keyword contained tb tc tf third syn keyword txl_keyword contained throw throwf time time-fields-local syn keyword txl_keyword contained time-fields-utc time-string-local time-string-utc time-usec syn keyword txl_keyword contained tofloat toint tok-str tok-where syn keyword txl_keyword contained tostring tostringp tprint transpose syn keyword txl_keyword contained tree-bind tree-case tree-find trie-add syn keyword txl_keyword contained trie-compress trie-lookup-begin trie-lookup-feed-char trie-value-at syn keyword txl_keyword contained trim-str true trunc trunc-rem syn keyword txl_keyword contained tuples txr-case txr-if txr-when syn keyword txl_keyword contained typeof unget-byte unget-char uniq syn keyword txl_keyword contained unique unless unquote until 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 w-continued w-coredump syn keyword txl_keyword contained w-exitstatus w-ifcontinued w-ifexited w-ifsignaled syn keyword txl_keyword contained w-ifstopped w-nohang w-stopsig w-termsig syn keyword txl_keyword contained w-untraced wait weave when syn keyword txl_keyword contained whenlet where while while* syn keyword txl_keyword contained whilet width with-saved-vars wrap syn keyword txl_keyword contained wrap* zap 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"