annotate runtime/syntax/murphi.vim @ 26780:b24b2217ff9e v8.2.3918

patch 8.2.3918: function list test fails Commit: https://github.com/vim/vim/commit/be4e223eadaa765bf2957f196e4d4b6014057bd1 Author: Bram Moolenaar <Bram@vim.org> Date: Mon Dec 27 21:42:57 2021 +0000 patch 8.2.3918: function list test fails Problem: Function list test fails. Solution: Adjust the test for the new location of the function list.
author Bram Moolenaar <Bram@vim.org>
date Mon, 27 Dec 2021 22:45:04 +0100
parents cc953757ed2a
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
11659
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
1 " Vim syntax file
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
2 " Language: Murphi model checking language
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
3 " Maintainer: Matthew Fernandez <matthew.fernandez@gmail.com>
17909
cc953757ed2a Runtime files update.
Bram Moolenaar <Bram@vim.org>
parents: 12254
diff changeset
4 " Last Change: 2019 Aug 27
11659
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
5 " Version: 2
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
6 " Remark: Originally authored by Diego Ongaro <ongaro@cs.stanford.edu>
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
7
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
8 if version < 600
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
9 syntax clear
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
10 elseif exists("b:current_syntax")
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
11 finish
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
12 endif
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
13
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
14 " Keywords are case insensitive.
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
15 " Keep these in alphabetical order.
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
16 syntax case ignore
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
17 syn keyword murphiKeyword alias
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
18 syn keyword murphiStructure array
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
19 syn keyword murphiKeyword assert
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
20 syn keyword murphiKeyword begin
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
21 syn keyword murphiType boolean
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
22 syn keyword murphiKeyword by
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
23 syn keyword murphiLabel case
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
24 syn keyword murphiKeyword clear
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
25 syn keyword murphiLabel const
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
26 syn keyword murphiRepeat do
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
27 syn keyword murphiConditional else
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
28 syn keyword murphiConditional elsif
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
29 syn keyword murphiKeyword end
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
30 syn keyword murphiKeyword endalias
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
31 syn keyword murphiRepeat endexists
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
32 syn keyword murphiRepeat endfor
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
33 syn keyword murphiRepeat endforall
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
34 syn keyword murphiKeyword endfunction
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
35 syn keyword murphiConditional endif
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
36 syn keyword murphiKeyword endprocedure
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
37 syn keyword murphiStructure endrecord
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
38 syn keyword murphiKeyword endrule
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
39 syn keyword murphiKeyword endruleset
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
40 syn keyword murphiKeyword endstartstate
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
41 syn keyword murphiConditional endswitch
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
42 syn keyword murphiRepeat endwhile
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
43 syn keyword murphiStructure enum
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
44 syn keyword murphiKeyword error
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
45 syn keyword murphiRepeat exists
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
46 syn keyword murphiBoolean false
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
47 syn keyword murphiRepeat for
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
48 syn keyword murphiRepeat forall
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
49 syn keyword murphiKeyword function
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
50 syn keyword murphiConditional if
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
51 syn keyword murphiKeyword in
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
52 syn keyword murphiKeyword interleaved
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
53 syn keyword murphiLabel invariant
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
54 syn keyword murphiFunction ismember
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
55 syn keyword murphiFunction isundefined
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
56 syn keyword murphiKeyword log
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
57 syn keyword murphiStructure of
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
58 syn keyword murphiType multiset
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
59 syn keyword murphiFunction multisetadd
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
60 syn keyword murphiFunction multisetcount
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
61 syn keyword murphiFunction multisetremove
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
62 syn keyword murphiFunction multisetremovepred
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
63 syn keyword murphiKeyword procedure
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
64 syn keyword murphiKeyword program
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
65 syn keyword murphiKeyword put
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
66 syn keyword murphiStructure record
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
67 syn keyword murphiKeyword return
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
68 syn keyword murphiLabel rule
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
69 syn keyword murphiLabel ruleset
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
70 syn keyword murphiType scalarset
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
71 syn keyword murphiLabel startstate
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
72 syn keyword murphiConditional switch
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
73 syn keyword murphiConditional then
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
74 syn keyword murphiRepeat to
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
75 syn keyword murphiKeyword traceuntil
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
76 syn keyword murphiBoolean true
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
77 syn keyword murphiLabel type
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
78 syn keyword murphiKeyword undefine
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
79 syn keyword murphiStructure union
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
80 syn keyword murphiLabel var
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
81 syn keyword murphiRepeat while
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
82
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
83 syn keyword murphiTodo contained todo xxx fixme
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
84 syntax case match
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
85
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
86 " Integers.
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
87 syn match murphiNumber "\<\d\+\>"
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
88
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
89 " Operators and special characters.
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
90 syn match murphiOperator "[\+\-\*\/%&|=!<>:\?]\|\."
17909
cc953757ed2a Runtime files update.
Bram Moolenaar <Bram@vim.org>
parents: 12254
diff changeset
91 syn match murphiDelimiter "\(:=\@!\|[;,]\)"
11659
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
92 syn match murphiSpecial "[()\[\]]"
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
93
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
94 " Double equal sign is a common error: use one equal sign for equality testing.
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
95 syn match murphiError "==[^>]"he=e-1
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
96 " Double && and || are errors.
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
97 syn match murphiError "&&\|||"
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
98
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
99 " Strings. This is defined so late so that it overrides previous matches.
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
100 syn region murphiString start=+"+ end=+"+
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
101
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
102 " Comments. This is defined so late so that it overrides previous matches.
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
103 syn region murphiComment start="--" end="$" contains=murphiTodo
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
104 syn region murphiComment start="/\*" end="\*/" contains=murphiTodo
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
105
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
106 " Link the rules to some groups.
12254
8d76a56861ec Update runtime files
Christian Brabandt <cb@256bit.org>
parents: 11659
diff changeset
107 hi def link murphiComment Comment
8d76a56861ec Update runtime files
Christian Brabandt <cb@256bit.org>
parents: 11659
diff changeset
108 hi def link murphiString String
8d76a56861ec Update runtime files
Christian Brabandt <cb@256bit.org>
parents: 11659
diff changeset
109 hi def link murphiNumber Number
8d76a56861ec Update runtime files
Christian Brabandt <cb@256bit.org>
parents: 11659
diff changeset
110 hi def link murphiBoolean Boolean
8d76a56861ec Update runtime files
Christian Brabandt <cb@256bit.org>
parents: 11659
diff changeset
111 hi def link murphiIdentifier Identifier
8d76a56861ec Update runtime files
Christian Brabandt <cb@256bit.org>
parents: 11659
diff changeset
112 hi def link murphiFunction Function
8d76a56861ec Update runtime files
Christian Brabandt <cb@256bit.org>
parents: 11659
diff changeset
113 hi def link murphiStatement Statement
8d76a56861ec Update runtime files
Christian Brabandt <cb@256bit.org>
parents: 11659
diff changeset
114 hi def link murphiConditional Conditional
8d76a56861ec Update runtime files
Christian Brabandt <cb@256bit.org>
parents: 11659
diff changeset
115 hi def link murphiRepeat Repeat
8d76a56861ec Update runtime files
Christian Brabandt <cb@256bit.org>
parents: 11659
diff changeset
116 hi def link murphiLabel Label
8d76a56861ec Update runtime files
Christian Brabandt <cb@256bit.org>
parents: 11659
diff changeset
117 hi def link murphiOperator Operator
8d76a56861ec Update runtime files
Christian Brabandt <cb@256bit.org>
parents: 11659
diff changeset
118 hi def link murphiKeyword Keyword
8d76a56861ec Update runtime files
Christian Brabandt <cb@256bit.org>
parents: 11659
diff changeset
119 hi def link murphiType Type
8d76a56861ec Update runtime files
Christian Brabandt <cb@256bit.org>
parents: 11659
diff changeset
120 hi def link murphiStructure Structure
8d76a56861ec Update runtime files
Christian Brabandt <cb@256bit.org>
parents: 11659
diff changeset
121 hi def link murphiSpecial Special
8d76a56861ec Update runtime files
Christian Brabandt <cb@256bit.org>
parents: 11659
diff changeset
122 hi def link murphiDelimiter Delimiter
8d76a56861ec Update runtime files
Christian Brabandt <cb@256bit.org>
parents: 11659
diff changeset
123 hi def link murphiError Error
8d76a56861ec Update runtime files
Christian Brabandt <cb@256bit.org>
parents: 11659
diff changeset
124 hi def link murphiTodo Todo
11659
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
125
49c12c93abf3 Updated runtime files and translations.
Christian Brabandt <cb@256bit.org>
parents:
diff changeset
126 let b:current_syntax = "murphi"