vim: update release.sh to vim 7.3
[msysgit/mtrensch.git] / share / vim / vim72 / syntax / elf.vim
blob621e063ff8760b2c988139a5fc79a5d595e78252
1 " Vim syntax file
2 " Language:    ELF
3 " Maintainer:  Christian V. J. Brüssow <cvjb@cvjb.de>
4 " Last Change: Son 22 Jun 2003 20:43:14 CEST
5 " Filenames:   *.ab,*.am
6 " URL:         http://www.cvjb.de/comp/vim/elf.vim
7 " $Id: elf.vim,v 1.1 2004/06/13 19:52:27 vimboss Exp $
9 " ELF: Extensible Language Facility
10 "      This is the Applix Inc., Macro and Builder programming language.
11 "      It has nothing in common with the binary format called ELF.
13 " For version 5.x: Clear all syntax items
14 " For version 6.x: Quit when a syntax file was already loaded
15 if version < 600
16         syntax clear
17 elseif exists("b:current_syntax")
18         finish
19 endif
21 " Case does not matter
22 syn case ignore
24 " Environments
25 syn region elfEnvironment transparent matchgroup=Special start="{" matchgroup=Special end="}" contains=ALLBUT,elfBraceError
27 " Unmatched braces
28 syn match elfBraceError "}"
30 " All macros must have at least one of these definitions
31 syn keyword elfSpecial endmacro
32 syn region elfSpecial transparent matchgroup=Special start="^\(\(macro\)\|\(set\)\) \S\+$" matchgroup=Special end="^\(\(endmacro\)\|\(endset\)\)$" contains=ALLBUT,elfBraceError
34 " Preprocessor Commands
35 syn keyword elfPPCom define include
37 " Some keywords
38 syn keyword elfKeyword  false true null
39 syn keyword elfKeyword  var format object function endfunction
41 " Conditionals and loops
42 syn keyword elfConditional if else case of endcase for to next while until return goto
44 " All built-in elf macros end with an '@'
45 syn match elfMacro "[0-9_A-Za-z]\+@"
47 " Strings and characters
48 syn region elfString start=+"+  skip=+\\\\\|\\"+  end=+"+
50 " Numbers
51 syn match elfNumber "-\=\<[0-9]*\.\=[0-9_]\>"
53 " Comments
54 syn region elfComment start="/\*"  end="\*/"
55 syn match elfComment  "\'.*$"
57 syn sync ccomment elfComment
59 " Parenthesis
60 syn match elfParens "[\[\]()]"
62 " Punctuation
63 syn match elfPunct "[,;]"
65 " Define the default highlighting.
66 " For version 5.7 and earlier: only when not done already
67 " For version 5.8 and later: only when an item doesn't have highlighting yet
68 if version >= 508 || !exists("did_elf_syn_inits")
69         if version < 508
70                 let did_elf_syn_inits = 1
71                 command -nargs=+ HiLink hi link <args>
72         else
73                 command -nargs=+ HiLink hi def link <args>
74    endif
76   " The default methods for highlighting. Can be overridden later.
77   HiLink elfComment Comment
78   HiLink elfPPCom Include
79   HiLink elfKeyword Keyword
80   HiLink elfSpecial Special
81   HiLink elfEnvironment Special
82   HiLink elfBraceError Error
83   HiLink elfConditional Conditional
84   HiLink elfMacro Function
85   HiLink elfNumber Number
86   HiLink elfString String
87   HiLink elfParens Delimiter
88   HiLink elfPunct Delimiter
90   delcommand HiLink
91 endif
93 let b:current_syntax = "elf"
95 " vim:ts=8:sw=4:nocindent:smartindent: