-
Notifications
You must be signed in to change notification settings - Fork 2
/
joy.vim
60 lines (51 loc) · 1.51 KB
/
joy.vim
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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
" Vim syntax file
" Language: Joy
" Maintainer: Ivan Tomac
" Last Change: January, 32, 2005
if version < 600
syntax clear
elseif exists("b:current_syntax")
finish
endif
syntax case match
syntax match joyError oneline "]"
syntax match joySpecial /[()\.\;]/
syntax region joyString start=/"/ end=/"/
syntax region joyList matchgroup=joyBracket start=/\[/ end=/\]/ contains=ALL
syntax region joyComment start=/(\*/ end=/\*)/
syntax match joySymbol /[^\[\]"\.\; ]+/
syntax match joySpecial /==/
syntax match joyComment /[#].*/
syntax match joySpecial /LIBRA/
syntax match joySpecial /DEFINE/
syntax match joySpecial /HIDE/
syntax match joySpecial /IN/
syntax match joySpecial /END/
syntax match joySpecial /MODULE/
syntax match joySpecial /PRIVATE/
syntax match joySpecial /PUBLIC/
syntax match joySpecial /CONST/
syntax match joySpecial /INLINE/
syntax match joySpecial /%IF/
syntax match joySpecial /%SET/
syntax match joySpecial /%INCLUDE/
syntax match joySpecial /%PUT/
syntax match joySpecial /%LISTING/
syntax match joySpecial /%TRACE/
if version >= 508 || !exists("did_joy_syntax_inits")
if version < 508
let did_joy_syntax_inits = 1
command -nargs=+ HiLink hi link <args>
else
command -nargs=+ HiLink hi def link <args>
endif
HiLink joyString String
HiLink joySymbol Identifier
HiLink joyList Identifier
HiLink joySpecial Keyword
HiLink joyBracket Function
HiLink joyComment Comment
HiLink joyError Error
delcommand HiLink
endif
let b:current_syntax = "joy"