1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42
|
" Vim syntax file
" Language: Macaulay2
if exists("b:current_syntax")
finish
endif
syn region m2String start=/\/\/\// skip=/\(\/\/\)*\/\/[^\/]/ end=/\/\/\//
syn region m2String start=/"/ skip=/[^\\]\(\\\\\)*\\"/ end=/"/
syn match m2Comment /--.*$/
syn region m2Comment start=/-\*/ end=/\*-/
syn case match
syn keyword m2Boolean true false
syn keyword m2Keyword contained
\ @M2KEYWORDS@
syn keyword m2Datatype contained
\ @M2DATATYPES@
syn keyword m2Function container
\ @M2FUNCTIONS@
syn keyword m2Constant container
\ @M2CONSTANTS@
syn keyword m2Symbol contained
\ @M2SYMBOLS@
let b:current_syntax = "m2"
hi def link m2String String
hi def link m2Comment Comment
hi def link m2Boolean Boolean
hi def link m2Symbol Identifier
hi def link m2Keyword Keyword
hi def link m2Datatype Type
hi def link m2Function Function
hi def link m2Constant Constant
|