" VIM Syntax file for txr " Kaz Kylheku " INSTALL-HOWTO: " " 1. Create the directory .vim/syntax in your home directory and " put this file there. " 2. In your .vimrc, add this command to associate *.txr files " with the txr filetype. " :au BufRead,BufNewFile *.txr set filetype=txr | 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 txr_keyword contained accept all and assert syn keyword txr_keyword contained bind block cases cat syn keyword txr_keyword contained catch choose close coll syn keyword txr_keyword contained collect defex deffilter define syn keyword txr_keyword contained do end eof eol syn keyword txr_keyword contained fail filter finally flatten syn keyword txr_keyword contained forget freeform fuzz gather syn keyword txr_keyword contained last load local maybe syn keyword txr_keyword contained merge next none or syn keyword txr_keyword contained output rebind rep repeat syn keyword txr_keyword contained require set skip some syn keyword txr_keyword contained text throw trailer try syn keyword txr_keyword contained until var syn keyword txl_keyword contained * *args* *full-args* *gensym-counter* syn keyword txl_keyword contained *keyword-package* *random-state* *self-path* *stddebug* syn keyword txl_keyword contained *stderr* *stdin* *stdlog* *stdnull* syn keyword txl_keyword contained *stdout* *user-package* + - syn keyword txl_keyword contained / /= < <= syn keyword txl_keyword contained = > >= abs syn keyword txl_keyword contained acons acons-new aconsql-new acos syn keyword txl_keyword contained alist-nremove alist-remove all and syn keyword txl_keyword contained andf append append* append-each syn keyword txl_keyword contained append-each* apply ash asin syn keyword txl_keyword contained assoc assql atan atan2 syn keyword txl_keyword contained atom bignump block boundp syn keyword txl_keyword contained break-str call car cat-str syn keyword txl_keyword contained cat-vec catch cdr ceil syn keyword txl_keyword contained chain chdir chr-isalnum chr-isalpha syn keyword txl_keyword contained chr-isascii chr-iscntrl chr-isdigit chr-isgraph syn keyword txl_keyword contained chr-islower chr-isprint chr-ispunct chr-isspace 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 collect-each collect-each* syn keyword txl_keyword contained comb compl-span-str cond cons syn keyword txl_keyword contained conses conses* consp copy syn keyword txl_keyword contained copy-alist copy-cons copy-hash copy-list syn keyword txl_keyword contained copy-str copy-vec cos count-if syn keyword txl_keyword contained countq countql countqual cum-norm-dist syn keyword txl_keyword contained daemon dec defmacro defsymacro syn keyword txl_keyword contained defun defvar del delay syn keyword txl_keyword contained delete-package do dohash downcase-str syn keyword txl_keyword contained dwim each each* 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 exit exp syn keyword txl_keyword contained expt exptmod fboundp fifth syn keyword txl_keyword contained find find-if find-package first syn keyword txl_keyword contained fixnump flatten flatten* flip syn keyword txl_keyword contained flo-int flo-str floatp floor syn keyword txl_keyword contained flush-stream for for* force syn keyword txl_keyword contained format fourth fun func-get-env syn keyword txl_keyword contained func-get-form func-set-env functionp gcd syn keyword txl_keyword contained gen generate gensym get-byte syn keyword txl_keyword contained get-char get-hash-userdata get-line get-list-from-stream syn keyword txl_keyword contained get-sig-handler get-string-from-stream gethash 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 identity if iff iffi syn keyword txl_keyword contained inc inhash int-flo int-str syn keyword txl_keyword contained integerp intern interp-fun-p isqrt syn keyword txl_keyword contained keep-if keep-if* keywordp lambda syn keyword txl_keyword contained lazy-str lazy-str-force lazy-str-force-upto lazy-str-get-trailing-list syn keyword txl_keyword contained lazy-stream-cons lazy-stringp lcons-fun ldiff syn keyword txl_keyword contained length length-list length-str length-str-< syn keyword txl_keyword contained length-str-<= length-str-> length-str->= length-vec syn keyword txl_keyword contained let let* link lisp-parse syn keyword txl_keyword contained list list* list-str list-vector syn keyword txl_keyword contained listp log log-alert log-auth syn keyword txl_keyword contained log-authpriv log-cons log-crit log-daemon syn keyword txl_keyword contained log-debug log-emerg log-err log-info syn keyword txl_keyword contained log-ndelay log-notice log-nowait log-odelay syn keyword txl_keyword contained log-perror log-pid log-user log-warning syn keyword txl_keyword contained log10 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-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 makedev syn keyword txl_keyword contained mapcar mapcar* maphash mappend syn keyword txl_keyword contained mappend* mask match-fun match-regex syn keyword txl_keyword contained match-regex-right match-str match-str-tree max syn keyword txl_keyword contained memq memql memqual merge syn keyword txl_keyword contained min minor mkdir mknod syn keyword txl_keyword contained mkstring mod multi-sort n-choose-k syn keyword txl_keyword contained n-perm-k none not nreverse syn keyword txl_keyword contained null num-chr num-str numberp syn keyword txl_keyword contained oddp op open-command open-directory syn keyword txl_keyword contained open-file open-files open-files* open-pipe syn keyword txl_keyword contained open-process open-tail openlog or syn keyword txl_keyword contained orf packagep perm pop syn keyword txl_keyword contained pos pos-if posq posql syn keyword txl_keyword contained posqual pprinl pprint prinl syn keyword txl_keyword contained print prog1 progn prop syn keyword txl_keyword contained proper-listp push pushhash put-byte syn keyword txl_keyword contained put-char put-line put-string pwd syn keyword txl_keyword contained qquote quasi quote rand syn keyword txl_keyword contained random random-fixnum random-state-p range syn keyword txl_keyword contained range* rcomb read readlink syn keyword txl_keyword contained real-time-stream-p reduce-left reduce-right ref syn keyword txl_keyword contained refset regex-compile regex-parse regexp syn keyword txl_keyword contained regsub rehome-sym remhash remove-if syn keyword txl_keyword contained remove-if* remove-path remq remq* syn keyword txl_keyword contained remql remql* remqual remqual* syn keyword txl_keyword contained rename-path repeat replace replace-list syn keyword txl_keyword contained replace-str replace-vec rest return syn keyword txl_keyword contained return-from reverse rlcp rperm syn keyword txl_keyword contained rplaca rplacd s-ifblk s-ifchr syn keyword txl_keyword contained s-ifdir s-ififo s-iflnk s-ifmt syn keyword txl_keyword contained s-ifreg s-ifsock s-irgrp s-iroth syn keyword txl_keyword contained s-irusr s-irwxg s-irwxo s-irwxu syn keyword txl_keyword contained s-isgid s-isuid s-isvtx s-iwgrp syn keyword txl_keyword contained s-iwoth s-iwusr s-ixgrp s-ixoth syn keyword txl_keyword contained s-ixusr search-regex search-str search-str-tree syn keyword txl_keyword contained second seek-stream set set-diff syn keyword txl_keyword contained set-hash-userdata set-sig-handler sethash setlogmask syn keyword txl_keyword contained sig-abrt sig-alrm sig-bus sig-check syn keyword txl_keyword contained sig-chld sig-cont sig-fpe sig-hup syn keyword txl_keyword contained sig-ill sig-int sig-io sig-iot syn keyword txl_keyword contained sig-kill sig-lost sig-pipe sig-poll syn keyword txl_keyword contained sig-prof sig-pwr sig-quit sig-segv syn keyword txl_keyword contained sig-stkflt sig-stop sig-sys sig-term syn keyword txl_keyword contained sig-trap sig-tstp sig-ttin sig-ttou syn keyword txl_keyword contained sig-urg sig-usr1 sig-usr2 sig-vtalrm syn keyword txl_keyword contained sig-winch sig-xcpu sig-xfsz sin syn keyword txl_keyword contained sixth size-vec some sort syn keyword txl_keyword contained source-loc source-loc-str span-str splice syn keyword txl_keyword contained split-str split-str-set sqrt stat syn keyword txl_keyword contained stream-get-prop stream-set-prop streamp string-cmp syn keyword txl_keyword contained string-extend string-lt stringp sub syn keyword txl_keyword contained sub-list sub-str sub-vec 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 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 tok-str tostring tostringp tree-bind syn keyword txl_keyword contained tree-case tree-find trim-str trunc syn keyword txl_keyword contained typeof unget-byte unget-char unquote syn keyword txl_keyword contained upcase-str update url-decode url-encode syn keyword txl_keyword contained usleep uw-protect vec vec-push syn keyword txl_keyword contained vec-set-length vecref vector vector-list syn keyword txl_keyword contained vectorp with-saved-vars zerop syn match txr_error "@[\t ]*[*]\?[\t ]*." syn match txr_nested_error "[^\t `]\+" contained syn match txr_hashbang "^#!.*" syn match txr_atat "@[ \t]*@" syn match txr_comment "@[ \t]*[#;].*" syn match txr_contin "@[ \t]*\\$" syn match txr_char "@[ \t]*\\." syn match txr_char "@[ \t]*\\x[0-9A-Fa-f]\+" syn match txr_char "@[ \t]*\\[0-9]\+" syn match txr_variable "@[ \t]*[*]\?[ \t]*[A-Za-z_][A-Za-z0-9_]*" syn match txr_metanum "@[0-9]\+" syn match txr_regdir "@[ \t]*/\(\\/\|[^/]\|\\\n\)*/" syn match txr_chr "#\\x[A-Fa-f0-9]\+" contained syn match txr_chr "#\\o[0-9]\+" contained syn match txr_chr "#\\[^ \t\nA-Za-z0-9_]" contained syn match txr_chr "#\\[A-Za-z0-9_]\+" contained syn match txr_regex "/\(\\/\|[^/]\|\\\n\)*/" contained syn match txl_regex "#/\(\\/\|[^/]\|\\\n\)*/" contained syn match txr_ncomment ";.*" contained syn match txr_dot "\." contained syn match txr_num "#x[+\-]\?[0-9A-Fa-f]\+" contained syn match txr_num "#o[+\-]\?[0-7]\+" contained syn match txr_num "#b[+\-]\?[0-1]\+" contained syn match txr_num "[+\-]\?[0-9]\+" contained syn match txr_ident "[:@][A-Za-z0-9!#$%&*+\-<=>?\\^_~]\+" contained syn match txr_ident "[A-Za-z0-9!$%&*+\-<=>?\\_~]*[A-Za-z!$#%&*+\-<=>?\\^_~][A-Za-z0-9!$#%&*+\-<=>?\\^_~]*" contained syn match txl_ident "[:@][A-Za-z0-9!$%&*+\-<=>?\\\^_~/]\+" contained syn match txl_ident "[A-Za-z0-9!$%&*+\-<=>?\\_~/]*[A-Za-z!$#%&*+\-<=>?\\^_~/][A-Za-z0-9!$#%&*+\-<=>?\\^_~/]*" contained syn match txr_num "[+\-]\?[0-9]*[.][0-9]\+\([eE][+\-]\?[0-9]\+\)\?" contained syn match txr_num "[+\-]\?[0-9]\+\([eE][+\-]\?[0-9]\+\)" contained syn match txl_ident ":" contained 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_bracevar matchgroup=Delimiter start="@[ \t]*[*]\?{" matchgroup=Delimiter end="}" contains=txr_num,txr_ident,txr_string,txr_list,txr_bracket,txr_mlist,txr_mbracket,txr_regex,txr_quasilit,txr_chr,txr_nested_error syn region txr_directive matchgroup=Delimiter start="@[ \t]*(" matchgroup=Delimiter end=")" contains=txr_keyword,txr_string,txr_list,txr_bracket,txr_mlist,txr_mbracket,txr_quasilit,txr_num,txl_ident,txl_regex,txr_string,txr_chr,txr_quote,txr_unquote,txr_splice,txr_dot,txr_dotdot,txr_metaat,txr_ncomment,txr_nested_error syn region txr_list contained matchgroup=Delimiter start="#\?H\?(" matchgroup=Delimiter end=")" contains=txl_keyword,txr_string,txl_regex,txr_num,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 contained matchgroup=Delimiter start="\[" matchgroup=Delimiter end="\]" contains=txl_keyword,txr_string,txl_regex,txr_num,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 contained matchgroup=Delimiter start="@[ \t]*(" matchgroup=Delimiter end=")" contains=txl_keyword,txr_string,txl_regex,txr_num,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,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 contained oneline start=+"+ skip=+\\\\\|\\"+ end=+"+ syn region txr_quasilit contained oneline start=+`+ skip=+\\\\\|\\`+ end=+`+ contains=txr_variable,txr_metanum,txr_bracevar,txr_mlist,txr_mbracket 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_metanum Identifier hi def link txr_ident Identifier hi def link txl_ident Identifier hi def link txr_num Number 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_error Error hi def link txr_nested_error Error let b:current_syntax = "lisp"