Bram Moolenaar | 071d427 | 2004-06-13 20:20:40 +0000 | [diff] [blame] | 1 | " Vim syntax file |
| 2 | " Language: ATLAS |
| 3 | " Maintainer: Inaki Saez <jisaez@sfe.indra.es> |
| 4 | " Last Change: 2001 May 09 |
| 5 | |
Bram Moolenaar | 89bcfda | 2016-08-30 23:26:57 +0200 | [diff] [blame] | 6 | " quit when a syntax file was already loaded |
| 7 | if exists("b:current_syntax") |
Bram Moolenaar | 071d427 | 2004-06-13 20:20:40 +0000 | [diff] [blame] | 8 | finish |
| 9 | endif |
| 10 | |
| 11 | syn case ignore |
| 12 | |
| 13 | syn keyword atlasStatement begin terminate |
| 14 | syn keyword atlasStatement fill calculate compare |
| 15 | syn keyword atlasStatement setup connect close open disconnect reset |
| 16 | syn keyword atlasStatement initiate read fetch |
| 17 | syn keyword atlasStatement apply measure verify remove |
| 18 | syn keyword atlasStatement perform leave finish output delay |
| 19 | syn keyword atlasStatement prepare execute |
| 20 | syn keyword atlasStatement do |
| 21 | syn match atlasStatement "\<go[ ]\+to\>" |
| 22 | syn match atlasStatement "\<wait[ ]\+for\>" |
| 23 | |
| 24 | syn keyword atlasInclude include |
| 25 | syn keyword atlasDefine define require declare identify |
| 26 | |
| 27 | "syn keyword atlasReserved true false go nogo hi lo via |
| 28 | syn keyword atlasReserved true false |
| 29 | |
| 30 | syn keyword atlasStorageClass external global |
| 31 | |
| 32 | syn keyword atlasConditional if then else end |
| 33 | syn keyword atlasRepeat while for thru |
| 34 | |
| 35 | " Flags BEF and statement number |
| 36 | syn match atlasSpecial "^[BE ][ 0-9]\{,6}\>" |
| 37 | |
| 38 | " Number formats |
| 39 | syn match atlasHexNumber "\<X'[0-9A-F]\+'" |
| 40 | syn match atlasOctalNumber "\<O'[0-7]\+'" |
| 41 | syn match atlasBinNumber "\<B'[01]\+'" |
| 42 | syn match atlasNumber "\<\d\+\>" |
| 43 | "Floating point number part only |
| 44 | syn match atlasDecimalNumber "\.\d\+\([eE][-+]\=\d\)\=\>" |
| 45 | |
| 46 | syn region atlasFormatString start=+((+ end=+\())\)\|\()[ ]*\$\)+me=e-1 |
| 47 | syn region atlasString start=+\<C'+ end=+'+ oneline |
| 48 | |
| 49 | syn region atlasComment start=+^C+ end=+\$+ |
| 50 | syn region atlasComment2 start=+\$.\++ms=s+1 end=+$+ oneline |
| 51 | |
| 52 | syn match atlasIdentifier "'[A-Za-z0-9 ._-]\+'" |
| 53 | |
| 54 | "Synchronization with Statement terminator $ |
| 55 | syn sync match atlasTerminator grouphere atlasComment "^C" |
| 56 | syn sync match atlasTerminator groupthere NONE "\$" |
| 57 | syn sync maxlines=100 |
| 58 | |
| 59 | |
| 60 | " Define the default highlighting. |
Bram Moolenaar | 89bcfda | 2016-08-30 23:26:57 +0200 | [diff] [blame] | 61 | " Only when an item doesn't have highlighting yet |
| 62 | command -nargs=+ HiLink hi def link <args> |
Bram Moolenaar | 071d427 | 2004-06-13 20:20:40 +0000 | [diff] [blame] | 63 | |
Bram Moolenaar | 89bcfda | 2016-08-30 23:26:57 +0200 | [diff] [blame] | 64 | HiLink atlasConditional Conditional |
| 65 | HiLink atlasRepeat Repeat |
| 66 | HiLink atlasStatement Statement |
| 67 | HiLink atlasNumber Number |
| 68 | HiLink atlasHexNumber Number |
| 69 | HiLink atlasOctalNumber Number |
| 70 | HiLink atlasBinNumber Number |
| 71 | HiLink atlasDecimalNumber Float |
| 72 | HiLink atlasFormatString String |
| 73 | HiLink atlasString String |
| 74 | HiLink atlasComment Comment |
| 75 | HiLink atlasComment2 Comment |
| 76 | HiLink atlasInclude Include |
| 77 | HiLink atlasDefine Macro |
| 78 | HiLink atlasReserved PreCondit |
| 79 | HiLink atlasStorageClass StorageClass |
| 80 | HiLink atlasIdentifier NONE |
| 81 | HiLink atlasSpecial Special |
Bram Moolenaar | 071d427 | 2004-06-13 20:20:40 +0000 | [diff] [blame] | 82 | |
Bram Moolenaar | 89bcfda | 2016-08-30 23:26:57 +0200 | [diff] [blame] | 83 | delcommand HiLink |
Bram Moolenaar | 071d427 | 2004-06-13 20:20:40 +0000 | [diff] [blame] | 84 | |
| 85 | let b:current_syntax = "atlas" |
| 86 | |
| 87 | " vim: ts=8 |