annotate runtime/syntax/latte.vim @ 19767:4ee37e23b782

Added tag v8.2.0439 for changeset aa4cbdb676cd3dde5e939ec5cb078e2a7345cd6c
author Bram Moolenaar <Bram@vim.org>
date Mon, 23 Mar 2020 23:00:05 +0100
parents 46763b01cd9a
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1 " Vim syntax file
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
2 " Language: Latte
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
3 " Maintainer: Nick Moffitt, <nick@zork.net>
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
4 " Last Change: 14 June, 2000
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
5 "
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
6 " Notes:
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
7 " I based this on the TeX and Scheme syntax files (but mostly scheme).
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
8 " See http://www.latte.org for info on the language.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
9
10048
43efa4f5a8ea commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents: 7
diff changeset
10 " quit when a syntax file was already loaded
43efa4f5a8ea commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents: 7
diff changeset
11 if exists("b:current_syntax")
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
12 finish
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
13 endif
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
14
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
15 syn match latteError "[{}\\]"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
16 syn match latteOther "\\{"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
17 syn match latteOther "\\}"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
18 syn match latteOther "\\\\"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
19
10048
43efa4f5a8ea commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents: 7
diff changeset
20 setlocal iskeyword=33,43,45,48-57,63,65-90,95,97-122,_
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
21
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
22 syn region latteVar matchgroup=SpecialChar start=!\\[A-Za-z_]!rs=s+1 end=![^A-Za-z0-9?!+_-]!me=e-1 contains=ALLBUT,latteNumber,latteOther
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
23 syn region latteVar matchgroup=SpecialChar start=!\\[=\&][A-Za-z_]!rs=s+2 end=![^A-Za-z0-9?!+_-]!me=e-1 contains=ALLBUT,latteNumber,latteOther
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
24 syn region latteString start=+\\"+ skip=+\\\\"+ end=+\\"+
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
25
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
26 syn region latteGroup matchgroup=Delimiter start="{" skip="\\[{}]" matchgroup=Delimiter end="}" contains=ALLBUT,latteSyntax
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
27
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
28 syn region latteUnquote matchgroup=Delimiter start="\\,{" skip="\\[{}]" matchgroup=Delimiter end="}" contains=ALLBUT,latteSyntax
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
29 syn region latteSplice matchgroup=Delimiter start="\\,@{" skip="\\[{}]" matchgroup=Delimiter end="}" contains=ALLBUT,latteSyntax
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
30 syn region latteQuote matchgroup=Delimiter start="\\'{" skip="\\[{}]" matchgroup=Delimiter end="}"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
31 syn region latteQuote matchgroup=Delimiter start="\\`{" skip="\\[{}]" matchgroup=Delimiter end="}" contains=latteUnquote,latteSplice
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
32
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
33 syn match latteOperator '\\/'
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
34 syn match latteOperator '='
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
35
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
36 syn match latteComment "\\;.*$"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
37
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
38 " This was gathered by slurping in the index.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
39
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
40 syn keyword latteSyntax __FILE__ __latte-version__ contained
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
41 syn keyword latteSyntax _bal-tag _pre _tag add and append apply back contained
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
42 syn keyword latteSyntax caar cadr car cdar cddr cdr ceil compose contained
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
43 syn keyword latteSyntax concat cons def defmacro divide downcase contained
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
44 syn keyword latteSyntax empty? equal? error explode file-contents contained
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
45 syn keyword latteSyntax floor foreach front funcall ge? getenv contained
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
46 syn keyword latteSyntax greater-equal? greater? group group? gt? html contained
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
47 syn keyword latteSyntax if include lambda le? length less-equal? contained
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
48 syn keyword latteSyntax less? let lmap load-file load-library lt? macro contained
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
49 syn keyword latteSyntax member? modulo multiply not nth operator? contained
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
50 syn keyword latteSyntax or ordinary quote process-output push-back contained
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
51 syn keyword latteSyntax push-front quasiquote quote random rdc reverse contained
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
52 syn keyword latteSyntax set! snoc splicing unquote strict-html4 contained
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
53 syn keyword latteSyntax string-append string-ge? string-greater-equal? contained
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
54 syn keyword latteSyntax string-greater? string-gt? string-le? contained
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
55 syn keyword latteSyntax string-less-equal? string-less? string-lt? contained
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
56 syn keyword latteSyntax string? subseq substr subtract contained
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
57 syn keyword latteSyntax upcase useless warn while zero? contained
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
58
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
59
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
60 " If it's good enough for scheme...
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
61
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
62 syn sync match matchPlace grouphere NONE "^[^ \t]"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
63 " ... i.e. synchronize on a line that starts at the left margin
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
64
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
65 " Define the default highlighting.
10048
43efa4f5a8ea commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents: 7
diff changeset
66 " Only when an item doesn't have highlighting yet
43efa4f5a8ea commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents: 7
diff changeset
67
10051
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
68 hi def link latteSyntax Statement
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
69 hi def link latteVar Function
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
70
10051
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
71 hi def link latteString String
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
72 hi def link latteQuote String
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
73
10051
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
74 hi def link latteDelimiter Delimiter
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
75 hi def link latteOperator Operator
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
76
10051
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
77 hi def link latteComment Comment
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
78 hi def link latteError Error
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
79
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
80
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
81 let b:current_syntax = "latte"