aboutsummaryrefslogtreecommitdiff
path: root/vim/syntax/sil.vim
blob: 7797177dec0e7bf563be9fced8265e0ebd58f84b (plain) (blame)
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
" Clean syntax file
" Language: Simple imperative language
" Author:   Camil Staps <info@camilstaps.nl>

if exists("b:current_syntax")
  finish
endif

let s:cpo_save = &cpo
set cpo&vim

syn include @ABC syntax/abc.vim

syn keyword silConditional  if else while
syn keyword silStatement    return
syn keyword silType         Bool Int Void

syn match   silOperator     "[-~@#$%^?!+*<>\/|&=:.]\+" display

syn match   silInteger      "\<\d\+\>" display
syn keyword silBool         True False

syn match   silABC          "|\~.*$" contains=@ABC transparent

hi def link silConditional  Conditional
hi def link silStatement    Statement
hi def link silType         Type

hi def link silOperator     Operator

hi def link silInteger      Number
hi def link silBool         Boolean

let b:current_syntax = 'sil'

let &cpo = s:cpo_save
unlet s:cpo_save