annotate runtime/syntax/dylan.vim @ 10051:46763b01cd9a

commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c Author: Bram Moolenaar <Bram@vim.org> Date: Wed Aug 31 22:22:10 2016 +0200 Updated runtime files. Remove HiLink commands.
author Christian Brabandt <cb@256bit.org>
date Wed, 31 Aug 2016 22:30:08 +0200
parents 43efa4f5a8ea
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: Dylan
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
3 " Authors: Justus Pendleton <justus@acm.org>
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
4 " Brent A. Fulgham <bfulgham@debian.org>
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
5 " Last Change: Fri Sep 29 13:45:55 PDT 2000
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
6 "
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
7 " This syntax file is based on the Haskell, Perl, Scheme, and C
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
8 " syntax files.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
9
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
10 " Part 1: Syntax definition
10048
43efa4f5a8ea commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents: 7
diff changeset
11 " 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
12 if exists("b:current_syntax")
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
13 finish
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
14 endif
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
15
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
16 syn case ignore
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
17
10048
43efa4f5a8ea commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents: 7
diff changeset
18 setlocal lisp
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
19
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
20 " Highlight special characters (those that have backslashes) differently
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
21 syn match dylanSpecial display contained "\\\(x\x\+\|\o\{1,3}\|.\|$\)"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
22
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
23 " Keywords
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
24 syn keyword dylanBlock afterwards begin block cleanup end
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
25 syn keyword dylanClassMods abstract concrete primary inherited virtual
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
26 syn keyword dylanException exception handler signal
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
27 syn keyword dylanParamDefs method class function library macro interface
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
28 syn keyword dylanSimpleDefs constant variable generic primary
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
29 syn keyword dylanOther above below from by in instance local slot subclass then to
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
30 syn keyword dylanConditional if when select case else elseif unless finally otherwise then
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
31 syn keyword dylanRepeat begin for until while from to
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
32 syn keyword dylanStatement define let
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
33 syn keyword dylanImport use import export exclude rename create
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
34 syn keyword dylanMiscMods open sealed domain singleton sideways inline functional
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
35
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
36 " Matching rules for special forms
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
37 syn match dylanOperator "\s[-!%&\*\+/=\?@\\^|~:]\+[-#!>%&:\*\+/=\?@\\^|~]*"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
38 syn match dylanOperator "\(\<[A-Z][a-zA-Z0-9_']*\.\)\=:[-!#$%&\*\+./=\?@\\^|~:]*"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
39 " Numbers
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
40 syn match dylanNumber "\<[0-9]\+\>\|\<0[xX][0-9a-fA-F]\+\>\|\<0[oO][0-7]\+\>"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
41 syn match dylanNumber "\<[0-9]\+\.[0-9]\+\([eE][-+]\=[0-9]\+\)\=\>"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
42 " Booleans
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
43 syn match dylanBoolean "#t\|#f"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
44 " Comments
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
45 syn match dylanComment "//.*"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
46 syn region dylanComment start="/\*" end="\*/"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
47 " Strings
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
48 syn region dylanString start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=dySpecial
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
49 syn match dylanCharacter "'[^\\]'"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
50 " Constants, classes, and variables
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
51 syn match dylanConstant "$\<[a-zA-Z0-9\-]\+\>"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
52 syn match dylanClass "<\<[a-zA-Z0-9\-]\+\>>"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
53 syn match dylanVariable "\*\<[a-zA-Z0-9\-]\+\>\*"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
54 " Preconditions
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
55 syn region dylanPrecondit start="^\s*#\s*\(if\>\|else\>\|endif\>\)" skip="\\$" end="$"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
56
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
57 " These appear at the top of files (usually). I like to highlight the whole line
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
58 " so that the definition stands out. They should probably really be keywords, but they
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
59 " don't generally appear in the middle of a line of code.
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
60 syn region dylanHeader start="^[Mm]odule:" end="^$"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
61
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
62 " Define the default highlighting.
10048
43efa4f5a8ea commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents: 7
diff changeset
63 " Only when an item doesn't have highlighting yet
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
64
10051
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
65 hi def link dylanBlock PreProc
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
66 hi def link dylanBoolean Boolean
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
67 hi def link dylanCharacter Character
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
68 hi def link dylanClass Structure
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
69 hi def link dylanClassMods StorageClass
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
70 hi def link dylanComment Comment
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
71 hi def link dylanConditional Conditional
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
72 hi def link dylanConstant Constant
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
73 hi def link dylanException Exception
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
74 hi def link dylanHeader Macro
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
75 hi def link dylanImport Include
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
76 hi def link dylanLabel Label
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
77 hi def link dylanMiscMods StorageClass
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
78 hi def link dylanNumber Number
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
79 hi def link dylanOther Keyword
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
80 hi def link dylanOperator Operator
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
81 hi def link dylanParamDefs Keyword
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
82 hi def link dylanPrecondit PreCondit
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
83 hi def link dylanRepeat Repeat
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
84 hi def link dylanSimpleDefs Keyword
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
85 hi def link dylanStatement Macro
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
86 hi def link dylanString String
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
87 hi def link dylanVariable Identifier
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
88
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
89
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
90 let b:current_syntax = "dylan"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
91
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
92 " vim:ts=8