3 " Maintainer: Bram Moolenaar <Bram@vim.org>
4 " Last Change: 2001 Apr 25
6 " The Vgrindefs file is used to specify a language for vgrind
8 " For version 5.x: Clear all syntax items
9 " For version 6.x: Quit when a syntax file was already loaded
12 elseif exists("b:current_syntax")
17 syn match vgrindefsComment "^#.*"
19 " The fields that vgrind recognizes
20 syn match vgrindefsField ":ab="
21 syn match vgrindefsField ":ae="
22 syn match vgrindefsField ":pb="
23 syn match vgrindefsField ":bb="
24 syn match vgrindefsField ":be="
25 syn match vgrindefsField ":cb="
26 syn match vgrindefsField ":ce="
27 syn match vgrindefsField ":sb="
28 syn match vgrindefsField ":se="
29 syn match vgrindefsField ":lb="
30 syn match vgrindefsField ":le="
31 syn match vgrindefsField ":nc="
32 syn match vgrindefsField ":tl"
33 syn match vgrindefsField ":oc"
34 syn match vgrindefsField ":kw="
36 " Also find the ':' at the end of the line, so all ':' are highlighted
37 syn match vgrindefsField ":\\$"
38 syn match vgrindefsField ":$"
39 syn match vgrindefsField "\\$"
41 " Define the default highlighting.
42 " For version 5.7 and earlier: only when not done already
43 " For version 5.8 and later: only when an item doesn't have highlighting yet
44 if version >= 508 || !exists("did_vgrindefs_syntax_inits")
46 let did_vgrindefs_syntax_inits = 1
47 command -nargs=+ HiLink hi link <args>
49 command -nargs=+ HiLink hi def link <args>
52 " The default methods for highlighting. Can be overridden later
53 HiLink vgrindefsField Statement
54 HiLink vgrindefsComment Comment
59 let b:current_syntax = "vgrindefs"