Mercurial > vim
annotate runtime/syntax/fortran.vim @ 9512:60945959a955
Added tag v7.4.2036 for changeset c2e904cc064f7025feb2854d80cefe9fb2d01379
author | Christian Brabandt <cb@256bit.org> |
---|---|
date | Thu, 14 Jul 2016 22:15:07 +0200 |
parents | 88207f4b861a |
children | 03fa8a51e9dc |
rev | line source |
---|---|
7 | 1 " Vim syntax file |
7384
aea5ebf352c4
commit https://github.com/vim/vim/commit/256972a9849b5d575b62a6a71be5b6934b5b0e8b
Christian Brabandt <cb@256bit.org>
parents:
6530
diff
changeset
|
2 " Language: Fortran 2008 (and older: Fortran 2003, 95, 90, and 77) |
8303
88207f4b861a
commit https://github.com/vim/vim/commit/dae8d21dd291df6a6679a00be64e18bca0156576
Christian Brabandt <cb@256bit.org>
parents:
7384
diff
changeset
|
3 " Version: 0.97 |
88207f4b861a
commit https://github.com/vim/vim/commit/dae8d21dd291df6a6679a00be64e18bca0156576
Christian Brabandt <cb@256bit.org>
parents:
7384
diff
changeset
|
4 " Last Change: 2016 Feb. 26 |
6530 | 5 " Maintainer: Ajit J. Thakkar <ajit@unb.ca>; <http://www2.unb.ca/~ajit/> |
2370
454f314d0e61
Make it possible to load Perl dynamically on Unix. (James Vega)
Bram Moolenaar <bram@vim.org>
parents:
2034
diff
changeset
|
6 " Usage: For instructions, do :help fortran-syntax from Vim |
7 | 7 " Credits: |
8303
88207f4b861a
commit https://github.com/vim/vim/commit/dae8d21dd291df6a6679a00be64e18bca0156576
Christian Brabandt <cb@256bit.org>
parents:
7384
diff
changeset
|
8 " Version 0.1 (April 2000) was based on the fortran 77 syntax file by Mario Eusebio and |
88207f4b861a
commit https://github.com/vim/vim/commit/dae8d21dd291df6a6679a00be64e18bca0156576
Christian Brabandt <cb@256bit.org>
parents:
7384
diff
changeset
|
9 " Preben Guldberg. Since then, useful suggestions and contributions have been made, |
88207f4b861a
commit https://github.com/vim/vim/commit/dae8d21dd291df6a6679a00be64e18bca0156576
Christian Brabandt <cb@256bit.org>
parents:
7384
diff
changeset
|
10 " in chronological order, by: |
88207f4b861a
commit https://github.com/vim/vim/commit/dae8d21dd291df6a6679a00be64e18bca0156576
Christian Brabandt <cb@256bit.org>
parents:
7384
diff
changeset
|
11 " Andrej Panjkov, Bram Moolenaar, Thomas Olsen, Michael Sternberg, Christian Reile, |
7 | 12 " Walter Dieudonné, Alexander Wagner, Roman Bertle, Charles Rendleman, |
8303
88207f4b861a
commit https://github.com/vim/vim/commit/dae8d21dd291df6a6679a00be64e18bca0156576
Christian Brabandt <cb@256bit.org>
parents:
7384
diff
changeset
|
13 " Andrew Griffiths, Joe Krahn, Hendrik Merx, Matt Thompson, and Jan Hermann. |
7 | 14 |
3281 | 15 if exists("b:current_syntax") |
7 | 16 finish |
17 endif | |
18 | |
3237 | 19 let s:cpo_save = &cpo |
20 set cpo&vim | |
21 | |
3281 | 22 " Choose fortran_dialect using the priority: |
7384
aea5ebf352c4
commit https://github.com/vim/vim/commit/256972a9849b5d575b62a6a71be5b6934b5b0e8b
Christian Brabandt <cb@256bit.org>
parents:
6530
diff
changeset
|
23 " source file directive > buffer-local value > global value > file extension |
aea5ebf352c4
commit https://github.com/vim/vim/commit/256972a9849b5d575b62a6a71be5b6934b5b0e8b
Christian Brabandt <cb@256bit.org>
parents:
6530
diff
changeset
|
24 " first try using directive in first three lines of file |
3281 | 25 let b:fortran_retype = getline(1)." ".getline(2)." ".getline(3) |
26 if b:fortran_retype =~? '\<fortran_dialect\s*=\s*F\>' | |
27 let b:fortran_dialect = "F" | |
28 elseif b:fortran_retype =~? '\<fortran_dialect\s*=\s*f08\>' | |
29 let b:fortran_dialect = "f08" | |
30 elseif !exists("b:fortran_dialect") | |
31 if exists("g:fortran_dialect") && g:fortran_dialect =~# '\<F\|f08\>' | |
32 " try global variable | |
33 let b:fortran_dialect = g:fortran_dialect | |
34 else " nothing found, so use default | |
35 let b:fortran_dialect = "f08" | |
7 | 36 endif |
37 endif | |
3281 | 38 unlet! b:fortran_retype |
39 " make sure buffer-local value is not invalid | |
40 if b:fortran_dialect !~# '\<F\|f08\>' | |
41 let b:fortran_dialect = "f08" | |
7 | 42 endif |
43 | |
44 " Choose between fixed and free source form if this hasn't been done yet | |
45 if !exists("b:fortran_fixed_source") | |
3281 | 46 if b:fortran_dialect == "F" |
47 " F requires free source form | |
7 | 48 let b:fortran_fixed_source = 0 |
49 elseif exists("fortran_free_source") | |
3281 | 50 " User guarantees free source form for all fortran files |
7 | 51 let b:fortran_fixed_source = 0 |
52 elseif exists("fortran_fixed_source") | |
3281 | 53 " User guarantees fixed source form for all fortran files |
7 | 54 let b:fortran_fixed_source = 1 |
7384
aea5ebf352c4
commit https://github.com/vim/vim/commit/256972a9849b5d575b62a6a71be5b6934b5b0e8b
Christian Brabandt <cb@256bit.org>
parents:
6530
diff
changeset
|
55 elseif expand("%:e") ==? "f\<90\|95\|03\|08\>" |
aea5ebf352c4
commit https://github.com/vim/vim/commit/256972a9849b5d575b62a6a71be5b6934b5b0e8b
Christian Brabandt <cb@256bit.org>
parents:
6530
diff
changeset
|
56 " Free-form file extension defaults as in Intel ifort, gcc(gfortran), NAG, Pathscale, and Cray compilers |
aea5ebf352c4
commit https://github.com/vim/vim/commit/256972a9849b5d575b62a6a71be5b6934b5b0e8b
Christian Brabandt <cb@256bit.org>
parents:
6530
diff
changeset
|
57 let b:fortran_fixed_source = 0 |
aea5ebf352c4
commit https://github.com/vim/vim/commit/256972a9849b5d575b62a6a71be5b6934b5b0e8b
Christian Brabandt <cb@256bit.org>
parents:
6530
diff
changeset
|
58 elseif expand("%:e") ==? "f\|f77\|for" |
aea5ebf352c4
commit https://github.com/vim/vim/commit/256972a9849b5d575b62a6a71be5b6934b5b0e8b
Christian Brabandt <cb@256bit.org>
parents:
6530
diff
changeset
|
59 " Fixed-form file extension defaults |
aea5ebf352c4
commit https://github.com/vim/vim/commit/256972a9849b5d575b62a6a71be5b6934b5b0e8b
Christian Brabandt <cb@256bit.org>
parents:
6530
diff
changeset
|
60 let b:fortran_fixed_source = 1 |
7 | 61 else |
3281 | 62 " Modern fortran still allows both free and fixed source form. |
7 | 63 " Assume fixed source form unless signs of free source form |
2377
878562053ba3
Update Fortran indent and syntax file. (Ajit Thakkar)
Bram Moolenaar <bram@vim.org>
parents:
2370
diff
changeset
|
64 " are detected in the first five columns of the first s:lmax lines. |
7 | 65 " Detection becomes more accurate and time-consuming if more lines |
66 " are checked. Increase the limit below if you keep lots of comments at | |
67 " the very top of each file and you have a fast computer. | |
2377
878562053ba3
Update Fortran indent and syntax file. (Ajit Thakkar)
Bram Moolenaar <bram@vim.org>
parents:
2370
diff
changeset
|
68 let s:lmax = 500 |
878562053ba3
Update Fortran indent and syntax file. (Ajit Thakkar)
Bram Moolenaar <bram@vim.org>
parents:
2370
diff
changeset
|
69 if ( s:lmax > line("$") ) |
878562053ba3
Update Fortran indent and syntax file. (Ajit Thakkar)
Bram Moolenaar <bram@vim.org>
parents:
2370
diff
changeset
|
70 let s:lmax = line("$") |
7 | 71 endif |
72 let b:fortran_fixed_source = 1 | |
2377
878562053ba3
Update Fortran indent and syntax file. (Ajit Thakkar)
Bram Moolenaar <bram@vim.org>
parents:
2370
diff
changeset
|
73 let s:ln=1 |
878562053ba3
Update Fortran indent and syntax file. (Ajit Thakkar)
Bram Moolenaar <bram@vim.org>
parents:
2370
diff
changeset
|
74 while s:ln <= s:lmax |
878562053ba3
Update Fortran indent and syntax file. (Ajit Thakkar)
Bram Moolenaar <bram@vim.org>
parents:
2370
diff
changeset
|
75 let s:test = strpart(getline(s:ln),0,5) |
878562053ba3
Update Fortran indent and syntax file. (Ajit Thakkar)
Bram Moolenaar <bram@vim.org>
parents:
2370
diff
changeset
|
76 if s:test !~ '^[Cc*]' && s:test !~ '^ *[!#]' && s:test =~ '[^ 0-9\t]' && s:test !~ '^[ 0-9]*\t' |
7384
aea5ebf352c4
commit https://github.com/vim/vim/commit/256972a9849b5d575b62a6a71be5b6934b5b0e8b
Christian Brabandt <cb@256bit.org>
parents:
6530
diff
changeset
|
77 let b:fortran_fixed_source = 0 |
aea5ebf352c4
commit https://github.com/vim/vim/commit/256972a9849b5d575b62a6a71be5b6934b5b0e8b
Christian Brabandt <cb@256bit.org>
parents:
6530
diff
changeset
|
78 break |
7 | 79 endif |
2377
878562053ba3
Update Fortran indent and syntax file. (Ajit Thakkar)
Bram Moolenaar <bram@vim.org>
parents:
2370
diff
changeset
|
80 let s:ln = s:ln + 1 |
7 | 81 endwhile |
2377
878562053ba3
Update Fortran indent and syntax file. (Ajit Thakkar)
Bram Moolenaar <bram@vim.org>
parents:
2370
diff
changeset
|
82 unlet! s:lmax s:ln s:test |
7 | 83 endif |
84 endif | |
85 | |
86 syn case ignore | |
87 | |
3281 | 88 if b:fortran_fixed_source == 1 |
89 syn match fortranConstructName "^\s\{6,}\zs\a\w*\ze\s*:" | |
90 else | |
91 syn match fortranConstructName "^\s*\zs\a\w*\ze\s*:" | |
92 endif | |
93 if exists("fortran_more_precise") | |
94 syn match fortranConstructName "\(\<end\s*do\s\+\)\@<=\a\w*" | |
95 syn match fortranConstructName "\(\<end\s*if\s\+\)\@<=\a\w*" | |
96 syn match fortranConstructName "\(\<end\s*select\s\+\)\@<=\a\w*" | |
7 | 97 endif |
98 | |
3281 | 99 syn match fortranUnitHeader "\<end\>" |
819 | 100 syn match fortranType "\<character\>" |
101 syn match fortranType "\<complex\>" | |
102 syn match fortranType "\<integer\>" | |
7 | 103 syn keyword fortranType intrinsic |
104 syn match fortranType "\<implicit\>" | |
105 syn keyword fortranStructure dimension | |
106 syn keyword fortranStorageClass parameter save | |
107 syn match fortranUnitHeader "\<subroutine\>" | |
108 syn keyword fortranCall call | |
109 syn match fortranUnitHeader "\<function\>" | |
110 syn match fortranUnitHeader "\<program\>" | |
819 | 111 syn keyword fortranKeyword return stop |
7 | 112 syn keyword fortranConditional else then |
113 syn match fortranConditional "\<if\>" | |
3256 | 114 syn match fortranConditionalOb "\<if\s*(.*)\s*\d\+\s*,\s*\d\+\s*,\s*\d\+\s*$" |
7 | 115 syn match fortranRepeat "\<do\>" |
116 | |
117 syn keyword fortranTodo contained todo fixme | |
118 | |
119 "Catch errors caused by too many right parentheses | |
819 | 120 syn region fortranParen transparent start="(" end=")" contains=ALLBUT,fortranParenError,@fortranCommentGroup,cIncluded,@spell |
7 | 121 syn match fortranParenError ")" |
122 | |
123 syn match fortranOperator "\.\s*n\=eqv\s*\." | |
124 syn match fortranOperator "\.\s*\(and\|or\|not\)\s*\." | |
125 syn match fortranOperator "\(+\|-\|/\|\*\)" | |
3281 | 126 syn match fortranTypeOb "\<character\s*\*" |
7 | 127 |
128 syn match fortranBoolean "\.\s*\(true\|false\)\s*\." | |
129 | |
819 | 130 syn keyword fortranReadWrite backspace close endfile inquire open print read rewind write |
7 | 131 |
132 "If tabs are allowed then the left margin checks do not work | |
133 if exists("fortran_have_tabs") | |
134 syn match fortranTab "\t" transparent | |
135 else | |
136 syn match fortranTab "\t" | |
137 endif | |
138 | |
819 | 139 syn keyword fortranIO access blank direct exist file fmt form formatted iostat name named nextrec number opened rec recl sequential status unformatted unit |
7 | 140 |
3281 | 141 syn keyword fortranIntrinsicR alog alog10 amax0 amax1 amin0 amin1 amod cabs ccos cexp clog csin csqrt dabs dacos dasin datan datan2 dcos dcosh ddim dexp dint dlog dlog10 dmax1 dmin1 dmod dnint dsign dsin dsinh dsqrt dtan dtanh float iabs idim idint idnint ifix isign max0 max1 min0 min1 sngl |
7 | 142 |
143 " Intrinsics provided by some vendors | |
3256 | 144 syn keyword fortranExtraIntrinsic algama cdabs cdcos cdexp cdlog cdsin cdsqrt cqabs cqcos cqexp cqlog cqsin cqsqrt dcmplx dconjg derf derfc dfloat dgamma dimag dlgama iqint qabs qacos qasin qatan qatan2 qcmplx qconjg qcos qcosh qdim qerf qerfc qexp qgamma qimag qlgama qlog qlog10 qmax1 qmin1 qmod qnint qsign qsin qsinh qsqrt qtan qtanh |
7 | 145 |
3281 | 146 syn keyword fortranIntrinsic abs acos aimag aint anint asin atan atan2 char cmplx conjg cos cosh exp ichar index int log log10 max min nint sign sin sinh sqrt tan tanh |
147 syn match fortranIntrinsic "\<len\s*[(,]"me=s+3 | |
148 syn match fortranIntrinsic "\<real\s*("me=s+4 | |
7 | 149 syn match fortranType "\<implicit\s\+real" |
150 syn match fortranType "^\s*real\>" | |
3281 | 151 syn match fortranIntrinsic "\<logical\s*("me=s+7 |
7 | 152 syn match fortranType "\<implicit\s\+logical" |
153 syn match fortranType "^\s*logical\>" | |
154 | |
155 "Numbers of various sorts | |
156 " Integers | |
157 syn match fortranNumber display "\<\d\+\(_\a\w*\)\=\>" | |
158 " floating point number, without a decimal point | |
3281 | 159 syn match fortranFloatIll display "\<\d\+[deq][-+]\=\d\+\(_\a\w*\)\=\>" |
7 | 160 " floating point number, starting with a decimal point |
3281 | 161 syn match fortranFloatIll display "\.\d\+\([deq][-+]\=\d\+\)\=\(_\a\w*\)\=\>" |
7 | 162 " floating point number, no digits after decimal |
3281 | 163 syn match fortranFloatIll display "\<\d\+\.\([deq][-+]\=\d\+\)\=\(_\a\w*\)\=\>" |
7 | 164 " floating point number, D or Q exponents |
3281 | 165 syn match fortranFloatIll display "\<\d\+\.\d\+\([dq][-+]\=\d\+\)\=\(_\a\w*\)\=\>" |
7 | 166 " floating point number |
167 syn match fortranFloat display "\<\d\+\.\d\+\(e[-+]\=\d\+\)\=\(_\a\w*\)\=\>" | |
168 " Numbers in formats | |
169 syn match fortranFormatSpec display "\d*f\d\+\.\d\+" | |
170 syn match fortranFormatSpec display "\d*e[sn]\=\d\+\.\d\+\(e\d+\>\)\=" | |
171 syn match fortranFormatSpec display "\d*\(d\|q\|g\)\d\+\.\d\+\(e\d+\)\=" | |
172 syn match fortranFormatSpec display "\d\+x\>" | |
173 " The next match cannot be used because it would pick up identifiers as well | |
174 " syn match fortranFormatSpec display "\<\(a\|i\)\d\+" | |
175 | |
176 " Numbers as labels | |
177 syn match fortranLabelNumber display "^\d\{1,5}\s"me=e-1 | |
178 syn match fortranLabelNumber display "^ \d\{1,4}\s"ms=s+1,me=e-1 | |
179 syn match fortranLabelNumber display "^ \d\{1,3}\s"ms=s+2,me=e-1 | |
180 syn match fortranLabelNumber display "^ \d\d\=\s"ms=s+3,me=e-1 | |
181 syn match fortranLabelNumber display "^ \d\s"ms=s+4,me=e-1 | |
182 | |
3281 | 183 if exists("fortran_more_precise") |
7 | 184 " Numbers as targets |
185 syn match fortranTarget display "\(\<if\s*(.\+)\s*\)\@<=\(\d\+\s*,\s*\)\{2}\d\+\>" | |
186 syn match fortranTarget display "\(\<do\s\+\)\@<=\d\+\>" | |
187 syn match fortranTarget display "\(\<go\s*to\s*(\=\)\@<=\(\d\+\s*,\s*\)*\d\+\>" | |
188 endif | |
189 | |
3281 | 190 syn keyword fortranTypeR external |
191 syn keyword fortranIOR format | |
192 syn match fortranKeywordR "\<continue\>" | |
2370
454f314d0e61
Make it possible to load Perl dynamically on Unix. (James Vega)
Bram Moolenaar <bram@vim.org>
parents:
2034
diff
changeset
|
193 syn match fortranKeyword "^\s*\d\+\s\+continue\>" |
3256 | 194 syn match fortranKeyword "\<go\s*to\>" |
195 syn match fortranKeywordDel "\<go\s*to\ze\s\+.*,\s*(.*$" | |
196 syn match fortranKeywordOb "\<go\s*to\ze\s*(\d\+.*$" | |
3281 | 197 syn region fortranStringR start=+'+ end=+'+ contains=fortranContinueMark,fortranLeftMargin,fortranSerialNumber |
198 syn keyword fortranIntrinsicR dim lge lgt lle llt mod | |
3256 | 199 syn keyword fortranKeywordDel assign pause |
7 | 200 |
3281 | 201 syn match fortranType "\<type\>" |
202 syn keyword fortranType none | |
7 | 203 |
3281 | 204 syn keyword fortranStructure private public intent optional |
205 syn keyword fortranStructure pointer target allocatable | |
206 syn keyword fortranStorageClass in out | |
207 syn match fortranStorageClass "\<kind\s*="me=s+4 | |
208 syn match fortranStorageClass "\<len\s*="me=s+3 | |
7 | 209 |
3281 | 210 syn match fortranUnitHeader "\<module\>" |
211 syn keyword fortranUnitHeader use only contains | |
212 syn keyword fortranUnitHeader result operator assignment | |
213 syn match fortranUnitHeader "\<interface\>" | |
214 syn match fortranUnitHeader "\<recursive\>" | |
215 syn keyword fortranKeyword allocate deallocate nullify cycle exit | |
216 syn match fortranConditional "\<select\>" | |
217 syn keyword fortranConditional case default where elsewhere | |
7 | 218 |
3281 | 219 syn match fortranOperator "\(\(>\|<\)=\=\|==\|/=\|=\)" |
220 syn match fortranOperator "=>" | |
221 | |
222 syn region fortranString start=+"+ end=+"+ contains=fortranLeftMargin,fortranContinueMark,fortranSerialNumber | |
223 syn keyword fortranIO pad position action delim readwrite | |
224 syn keyword fortranIO eor advance nml | |
7 | 225 |
3281 | 226 syn keyword fortranIntrinsic adjustl adjustr all allocated any associated bit_size btest ceiling count cshift date_and_time digits dot_product eoshift epsilon exponent floor fraction huge iand ibclr ibits ibset ieor ior ishft ishftc lbound len_trim matmul maxexponent maxloc maxval merge minexponent minloc minval modulo mvbits nearest pack precision present product radix random_number random_seed range repeat reshape rrspacing |
227 syn keyword fortranIntrinsic scale scan selected_int_kind selected_real_kind set_exponent shape size spacing spread sum system_clock tiny transpose trim ubound unpack verify | |
228 syn match fortranIntrinsic "\<not\>\(\s*\.\)\@!"me=s+3 | |
229 syn match fortranIntrinsic "\<kind\>\s*[(,]"me=s+4 | |
7 | 230 |
3281 | 231 syn match fortranUnitHeader "\<end\s*function" |
232 syn match fortranUnitHeader "\<end\s*interface" | |
233 syn match fortranUnitHeader "\<end\s*module" | |
234 syn match fortranUnitHeader "\<end\s*program" | |
235 syn match fortranUnitHeader "\<end\s*subroutine" | |
236 syn match fortranRepeat "\<end\s*do" | |
237 syn match fortranConditional "\<end\s*where" | |
238 syn match fortranConditional "\<select\s*case" | |
239 syn match fortranConditional "\<end\s*select" | |
240 syn match fortranType "\<end\s*type" | |
241 syn match fortranType "\<in\s*out" | |
7 | 242 |
3682 | 243 syn keyword fortranType procedure |
244 syn match fortranType "\<module\ze\s\+procedure\>" | |
3281 | 245 syn keyword fortranIOR namelist |
246 syn keyword fortranConditionalR while | |
247 syn keyword fortranIntrinsicR achar iachar transfer | |
7 | 248 |
3281 | 249 syn keyword fortranInclude include |
250 syn keyword fortranStorageClassR sequence | |
7 | 251 |
252 syn match fortranConditional "\<end\s*if" | |
253 syn match fortranIO contains=fortranOperator "\<e\(nd\|rr\)\s*=\s*\d\+" | |
254 syn match fortranConditional "\<else\s*if" | |
255 | |
3256 | 256 syn keyword fortranUnitHeaderOb entry |
7 | 257 syn match fortranTypeR display "double\s\+precision" |
258 syn match fortranTypeR display "double\s\+complex" | |
259 syn match fortranUnitHeaderR display "block\s\+data" | |
260 syn keyword fortranStorageClassR common equivalence data | |
3281 | 261 syn keyword fortranIntrinsicR dble dprod |
262 syn match fortranOperatorR "\.\s*[gl][et]\s*\." | |
263 syn match fortranOperatorR "\.\s*\(eq\|ne\)\s*\." | |
7 | 264 |
3281 | 265 syn keyword fortranRepeat forall |
266 syn match fortranRepeat "\<end\s*forall" | |
267 syn keyword fortranIntrinsic null cpu_time | |
268 syn match fortranType "\<elemental\>" | |
269 syn match fortranType "\<pure\>" | |
270 if exists("fortran_more_precise") | |
271 syn match fortranConstructName "\(\<end\s*forall\s\+\)\@<=\a\w*\>" | |
7 | 272 endif |
273 | |
3281 | 274 if b:fortran_dialect == "f08" |
2370
454f314d0e61
Make it possible to load Perl dynamically on Unix. (James Vega)
Bram Moolenaar <bram@vim.org>
parents:
2034
diff
changeset
|
275 " F2003 |
3281 | 276 syn keyword fortranIntrinsic command_argument_count get_command get_command_argument get_environment_variable is_iostat_end is_iostat_eor move_alloc new_line selected_char_kind same_type_as extends_type_of |
2370
454f314d0e61
Make it possible to load Perl dynamically on Unix. (James Vega)
Bram Moolenaar <bram@vim.org>
parents:
2034
diff
changeset
|
277 " ISO_C_binding |
3281 | 278 syn keyword fortranConstant c_null_char c_alert c_backspace c_form_feed c_new_line c_carriage_return c_horizontal_tab c_vertical_tab |
279 syn keyword fortranConstant c_int c_short c_long c_long_long c_signed_char c_size_t c_int8_t c_int16_t c_int32_t c_int64_t c_int_least8_t c_int_least16_t c_int_least32_t c_int_least64_t c_int_fast8_t c_int_fast16_t c_int_fast32_t c_int_fast64_t c_intmax_t C_intptr_t c_float c_double c_long_double c_float_complex c_double_complex c_long_double_complex c_bool c_char c_null_ptr c_null_funptr | |
280 syn keyword fortranIntrinsic iso_c_binding c_loc c_funloc c_associated c_f_pointer c_f_procpointer | |
281 syn keyword fortranType c_ptr c_funptr | |
2370
454f314d0e61
Make it possible to load Perl dynamically on Unix. (James Vega)
Bram Moolenaar <bram@vim.org>
parents:
2034
diff
changeset
|
282 " ISO_Fortran_env |
3281 | 283 syn keyword fortranConstant iso_fortran_env character_storage_size error_unit file_storage_size input_unit iostat_end iostat_eor numeric_storage_size output_unit |
2370
454f314d0e61
Make it possible to load Perl dynamically on Unix. (James Vega)
Bram Moolenaar <bram@vim.org>
parents:
2034
diff
changeset
|
284 " IEEE_arithmetic |
3281 | 285 syn keyword fortranIntrinsic ieee_arithmetic ieee_support_underflow_control ieee_get_underflow_mode ieee_set_underflow_mode |
2370
454f314d0e61
Make it possible to load Perl dynamically on Unix. (James Vega)
Bram Moolenaar <bram@vim.org>
parents:
2034
diff
changeset
|
286 |
3281 | 287 syn keyword fortranReadWrite flush wait |
288 syn keyword fortranIO decimal round iomsg | |
289 syn keyword fortranType asynchronous nopass non_overridable pass protected volatile abstract extends import | |
290 syn keyword fortranType non_intrinsic value bind deferred generic final enumerator | |
291 syn match fortranType "\<class\>" | |
292 syn match fortranType "\<associate\>" | |
293 syn match fortranType "\<end\s*associate" | |
294 syn match fortranType "\<enum\s*,\s*bind\s*(\s*c\s*)" | |
295 syn match fortranType "\<end\s*enum" | |
296 syn match fortranConditional "\<select\s*type" | |
297 syn match fortranConditional "\<type\s*is\>" | |
298 syn match fortranConditional "\<class\s*is\>" | |
299 syn match fortranUnitHeader "\<abstract\s*interface\>" | |
300 syn match fortranOperator "\([\|]\)" | |
2370
454f314d0e61
Make it possible to load Perl dynamically on Unix. (James Vega)
Bram Moolenaar <bram@vim.org>
parents:
2034
diff
changeset
|
301 |
454f314d0e61
Make it possible to load Perl dynamically on Unix. (James Vega)
Bram Moolenaar <bram@vim.org>
parents:
2034
diff
changeset
|
302 " F2008 |
3281 | 303 syn keyword fortranIntrinsic acosh asinh atanh bessel_j0 bessel_j1 bessel_jn bessel_y0 bessel_y1 bessel_yn erf erfc erfc_scaled gamma log_gamma hypot norm2 |
304 syn keyword fortranIntrinsic atomic_define atomic_ref execute_command_line leadz trailz storage_size merge_bits | |
305 syn keyword fortranIntrinsic bge bgt ble blt dshiftl dshiftr findloc iall iany iparity image_index lcobound ucobound maskl maskr num_images parity popcnt poppar shifta shiftl shiftr this_image | |
306 syn keyword fortranIO newunit | |
307 syn keyword fortranType contiguous | |
6530 | 308 |
309 " CUDA fortran | |
310 syn match fortranTypeCUDA "\<attributes\>" | |
311 syn keyword fortranTypeCUDA host global device value | |
312 syn keyword fortranTypeCUDA shared constant pinned texture | |
313 syn keyword fortranTypeCUDA dim1 dim2 dim3 dim4 | |
314 syn keyword fortranTypeCUDA cudadeviceprop cuda_count_kind cuda_stream_kind | |
315 syn keyword fortranTypeCUDA cudaEvent cudaFuncAttributes cudaArrayPtr | |
316 syn keyword fortranTypeCUDA cudaSymbol cudaChannelFormatDesc cudaPitchedPtr | |
317 syn keyword fortranTypeCUDA cudaExtent cudaMemcpy3DParms | |
318 syn keyword fortranTypeCUDA cudaFuncCachePreferNone cudaFuncCachePreferShared | |
319 syn keyword fortranTypeCUDA cudaFuncCachePreferL1 cudaLimitStackSize | |
320 syn keyword fortranTypeCUDA cudaLimitPrintfSize cudaLimitMallocHeapSize | |
321 syn keyword fortranTypeCUDA cudaSharedMemBankSizeDefault cudaSharedMemBankSizeFourByte cudaSharedMemBankSizeEightByte | |
322 syn keyword fortranTypeCUDA cudaEventDefault cudaEventBlockingSync cudaEventDisableTiming | |
323 syn keyword fortranTypeCUDA cudaMemcpyHostToDevice cudaMemcpyDeviceToHost | |
324 syn keyword fortranTypeCUDA cudaMemcpyDeviceToDevice | |
325 syn keyword fortranTypeCUDA cudaErrorNotReady cudaSuccess cudaErrorInvalidValue | |
326 syn keyword fortranTypeCUDA c_devptr | |
327 | |
328 syn match fortranStringCUDA "blockidx%[xyz]" | |
329 syn match fortranStringCUDA "blockdim%[xyz]" | |
330 syn match fortranStringCUDA "griddim%[xyz]" | |
331 syn match fortranStringCUDA "threadidx%[xyz]" | |
332 | |
333 syn keyword fortranIntrinsicCUDA warpsize syncthreads syncthreads_and syncthreads_count syncthreads_or threadfence threadfence_block threadfence_system gpu_time allthreads anythread ballot | |
334 syn keyword fortranIntrinsicCUDA atomicadd atomicsub atomicmax atomicmin atomicand atomicor atomicxor atomicexch atomicinc atomicdec atomiccas sizeof __shfl __shfl_up __shfl_down __shfl_xor | |
335 syn keyword fortranIntrinsicCUDA cudaChooseDevice cudaDeviceGetCacheConfig cudaDeviceGetLimit cudaDeviceGetSharedMemConfig cudaDeviceReset cudaDeviceSetCacheConfig cudaDeviceSetLimit cudaDeviceSetSharedMemConfig cudaDeviceSynchronize cudaGetDevice cudaGetDeviceCount cudaGetDeviceProperties cudaSetDevice cudaSetDeviceFlags cudaSetValidDevices | |
336 syn keyword fortranIntrinsicCUDA cudaThreadExit cudaThreadSynchronize cudaGetLastError cudaGetErrorString cudaPeekAtLastError cudaStreamCreate cudaStreamDestroy cudaStreamQuery cudaStreamSynchronize cudaStreamWaitEvent cudaEventCreate cudaEventCreateWithFlags cudaEventDestroy cudaEventElapsedTime cudaEventQuery cudaEventRecord cudaEventSynchronize | |
337 syn keyword fortranIntrinsicCUDA cudaFuncGetAttributes cudaFuncSetCacheConfig cudaFuncSetSharedMemConfig cudaSetDoubleForDevice cudaSetDoubleForHost cudaFree cudaFreeArray cudaFreeHost cudaGetSymbolAddress cudaGetSymbolSize | |
338 syn keyword fortranIntrinsicCUDA cudaHostAlloc cudaHostGetDevicePointer cudaHostGetFlags cudaHostRegister cudaHostUnregister cudaMalloc cudaMallocArray cudaMallocHost cudaMallocPitch cudaMalloc3D cudaMalloc3DArray | |
339 syn keyword fortranIntrinsicCUDA cudaMemcpy cudaMemcpyArraytoArray cudaMemcpyAsync cudaMemcpyFromArray cudaMemcpyFromSymbol cudaMemcpyFromSymbolAsync cudaMemcpyPeer cudaMemcpyPeerAsync cudaMemcpyToArray cudaMemcpyToSymbol cudaMemcpyToSymbolAsync cudaMemcpy2D cudaMemcpy2DArrayToArray cudaMemcpy2DAsync cudaMemcpy2DFromArray cudaMemcpy2DToArray cudaMemcpy3D cudaMemcpy3DAsync | |
340 syn keyword fortranIntrinsicCUDA cudaMemGetInfo cudaMemset cudaMemset2D cudaMemset3D cudaDeviceCanAccessPeer cudaDeviceDisablePeerAccess cudaDeviceEnablePeerAccess cudaPointerGetAttributes cudaDriverGetVersion cudaRuntimeGetVersion | |
341 | |
342 syn region none matchgroup=fortranType start="<<<" end=">>>" contains=ALLBUT,none | |
2370
454f314d0e61
Make it possible to load Perl dynamically on Unix. (James Vega)
Bram Moolenaar <bram@vim.org>
parents:
2034
diff
changeset
|
343 endif |
454f314d0e61
Make it possible to load Perl dynamically on Unix. (James Vega)
Bram Moolenaar <bram@vim.org>
parents:
2034
diff
changeset
|
344 |
7 | 345 syn cluster fortranCommentGroup contains=fortranTodo |
346 | |
347 if (b:fortran_fixed_source == 1) | |
348 if !exists("fortran_have_tabs") | |
349 "Flag items beyond column 72 | |
350 syn match fortranSerialNumber excludenl "^.\{73,}$"lc=72 | |
351 "Flag left margin errors | |
352 syn match fortranLabelError "^.\{-,4}[^0-9 ]" contains=fortranTab | |
353 syn match fortranLabelError "^.\{4}\d\S" | |
354 endif | |
2034 | 355 syn match fortranComment excludenl "^[!c*].*$" contains=@fortranCommentGroup,@spell |
7 | 356 syn match fortranLeftMargin transparent "^ \{5}" |
357 syn match fortranContinueMark display "^.\{5}\S"lc=5 | |
358 else | |
359 syn match fortranContinueMark display "&" | |
360 endif | |
361 | |
3281 | 362 syn match fortranComment excludenl "!.*$" contains=@fortranCommentGroup,@spell |
7 | 363 |
364 "cpp is often used with Fortran | |
365 syn match cPreProc "^\s*#\s*\(define\|ifdef\)\>.*" | |
366 syn match cPreProc "^\s*#\s*\(elif\|if\)\>.*" | |
367 syn match cPreProc "^\s*#\s*\(ifndef\|undef\)\>.*" | |
368 syn match cPreCondit "^\s*#\s*\(else\|endif\)\>.*" | |
369 syn region cIncluded contained start=+"[^(]+ skip=+\\\\\|\\"+ end=+"+ contains=fortranLeftMargin,fortranContinueMark,fortranSerialNumber | |
370 syn match cIncluded contained "<[^>]*>" | |
371 syn match cInclude "^\s*#\s*include\>\s*["<]" contains=cIncluded | |
372 | |
373 "Synchronising limits assume that comment and continuation lines are not mixed | |
819 | 374 if exists("fortran_fold") || exists("fortran_more_precise") |
375 syn sync fromstart | |
376 elseif (b:fortran_fixed_source == 0) | |
2370
454f314d0e61
Make it possible to load Perl dynamically on Unix. (James Vega)
Bram Moolenaar <bram@vim.org>
parents:
2034
diff
changeset
|
377 syn sync linecont "&" minlines=30 |
7 | 378 else |
2370
454f314d0e61
Make it possible to load Perl dynamically on Unix. (James Vega)
Bram Moolenaar <bram@vim.org>
parents:
2034
diff
changeset
|
379 syn sync minlines=30 |
7 | 380 endif |
381 | |
3281 | 382 if exists("fortran_fold") |
7 | 383 |
384 if (b:fortran_fixed_source == 1) | |
385 syn region fortranProgram transparent fold keepend start="^\s*program\s\+\z(\a\w*\)" skip="^\([!c*]\|\s*#\).*$" excludenl end="\<end\s*\(program\(\s\+\z1\>\)\=\|$\)" contains=ALLBUT,fortranModule | |
386 syn region fortranModule transparent fold keepend start="^\s*module\s\+\(procedure\)\@!\z(\a\w*\)" skip="^\([!c*]\|\s*#\).*$" excludenl end="\<end\s*\(module\(\s\+\z1\>\)\=\|$\)" contains=ALLBUT,fortranProgram | |
819 | 387 syn region fortranFunction transparent fold keepend extend start="^\s*\(elemental \|pure \|recursive \)\=\s*\(\(\(real \|integer \|logical \|complex \|double \s*precision \)\s*\((\(\s*kind\s*=\)\=\s*\w\+\s*)\)\=\)\|type\s\+(\s*\w\+\s*) \|character \((\(\s*len\s*=\)\=\s*\d\+\s*)\|(\(\s*kind\s*=\)\=\s*\w\+\s*)\)\=\)\=\s*function\s\+\z(\a\w*\)" skip="^\([!c*]\|\s*#\).*$" excludenl end="\<end\s*\($\|function\(\s\+\z1\>\)\=\)" contains=ALLBUT,fortranProgram,fortranModule |
7 | 388 syn region fortranSubroutine transparent fold keepend extend start="^\s*\(elemental \|pure \|recursive \)\=\s*subroutine\s\+\z(\a\w*\)" skip="^\([!c*]\|\s*#\).*$" excludenl end="\<end\s*\($\|subroutine\(\s\+\z1\>\)\=\)" contains=ALLBUT,fortranProgram,fortranModule |
2370
454f314d0e61
Make it possible to load Perl dynamically on Unix. (James Vega)
Bram Moolenaar <bram@vim.org>
parents:
2034
diff
changeset
|
389 syn region fortranBlockData transparent fold keepend start="\<block\s*data\(\s\+\z(\a\w*\)\)\=" skip="^\([!c*]\|\s*#\).*$" excludenl end="\<end\s*\($\|block\s*data\(\s\+\z1\>\)\=\)" contains=ALLBUT,fortranProgram,fortranModule,fortranSubroutine,fortranFunction,fortran77Loop,fortranCase,fortran90Loop,fortranIfBlock |
7 | 390 syn region fortranInterface transparent fold keepend extend start="^\s*interface\>" skip="^\([!c*]\|\s*#\).*$" excludenl end="\<end\s*interface\>" contains=ALLBUT,fortranProgram,fortranModule,fortran77Loop,fortranCase,fortran90Loop,fortranIfBlock |
2370
454f314d0e61
Make it possible to load Perl dynamically on Unix. (James Vega)
Bram Moolenaar <bram@vim.org>
parents:
2034
diff
changeset
|
391 syn region fortranTypeDef transparent fold keepend extend start="^\s*type\s*\(,\s*\(public\|private\)\)\=\s*::" skip="^\([!c*]\|\s*#\).*$" excludenl end="\<end\s*type\>" contains=ALLBUT,fortranProgram,fortranModule,fortran77Loop,fortranCase,fortran90Loop,fortranIfBlock |
7 | 392 else |
393 syn region fortranProgram transparent fold keepend start="^\s*program\s\+\z(\a\w*\)" skip="^\s*[!#].*$" excludenl end="\<end\s*\(program\(\s\+\z1\>\)\=\|$\)" contains=ALLBUT,fortranModule | |
394 syn region fortranModule transparent fold keepend start="^\s*module\s\+\(procedure\)\@!\z(\a\w*\)" skip="^\s*[!#].*$" excludenl end="\<end\s*\(module\(\s\+\z1\>\)\=\|$\)" contains=ALLBUT,fortranProgram | |
819 | 395 syn region fortranFunction transparent fold keepend extend start="^\s*\(elemental \|pure \|recursive \)\=\s*\(\(\(real \|integer \|logical \|complex \|double \s*precision \)\s*\((\(\s*kind\s*=\)\=\s*\w\+\s*)\)\=\)\|type\s\+(\s*\w\+\s*) \|character \((\(\s*len\s*=\)\=\s*\d\+\s*)\|(\(\s*kind\s*=\)\=\s*\w\+\s*)\)\=\)\=\s*function\s\+\z(\a\w*\)" skip="^\s*[!#].*$" excludenl end="\<end\s*\($\|function\(\s\+\z1\>\)\=\)" contains=ALLBUT,fortranProgram,fortranModule |
7 | 396 syn region fortranSubroutine transparent fold keepend extend start="^\s*\(elemental \|pure \|recursive \)\=\s*subroutine\s\+\z(\a\w*\)" skip="^\s*[!#].*$" excludenl end="\<end\s*\($\|subroutine\(\s\+\z1\>\)\=\)" contains=ALLBUT,fortranProgram,fortranModule |
2370
454f314d0e61
Make it possible to load Perl dynamically on Unix. (James Vega)
Bram Moolenaar <bram@vim.org>
parents:
2034
diff
changeset
|
397 syn region fortranBlockData transparent fold keepend start="\<block\s*data\(\s\+\z(\a\w*\)\)\=" skip="^\s*[!#].*$" excludenl end="\<end\s*\($\|block\s*data\(\s\+\z1\>\)\=\)" contains=ALLBUT,fortranProgram,fortranModule,fortranSubroutine,fortranFunction,fortran77Loop,fortranCase,fortran90Loop,fortranIfBlock |
7 | 398 syn region fortranInterface transparent fold keepend extend start="^\s*interface\>" skip="^\s*[!#].*$" excludenl end="\<end\s*interface\>" contains=ALLBUT,fortranProgram,fortranModule,fortran77Loop,fortranCase,fortran90Loop,fortranIfBlock |
2370
454f314d0e61
Make it possible to load Perl dynamically on Unix. (James Vega)
Bram Moolenaar <bram@vim.org>
parents:
2034
diff
changeset
|
399 syn region fortranTypeDef transparent fold keepend extend start="^\s*type\s*\(,\s*\(public\|private\)\)\=\s*::" skip="^\s*[!#].*$" excludenl end="\<end\s*type\>" contains=ALLBUT,fortranProgram,fortranModule,fortran77Loop,fortranCase,fortran90Loop,fortranIfBlock |
7 | 400 endif |
401 | |
402 if exists("fortran_fold_conditionals") | |
403 if (b:fortran_fixed_source == 1) | |
404 syn region fortran77Loop transparent fold keepend start="\<do\s\+\z(\d\+\)" end="^\s*\z1\>" contains=ALLBUT,fortranUnitHeader,fortranStructure,fortranStorageClass,fortranType,fortranProgram,fortranModule,fortranSubroutine,fortranFunction,fortranBlockData | |
405 syn region fortran90Loop transparent fold keepend extend start="\(\<end\s\+\)\@<!\<do\(\s\+\a\|\s*$\)" skip="^\([!c*]\|\s*#\).*$" excludenl end="\<end\s*do\>" contains=ALLBUT,fortranUnitHeader,fortranStructure,fortranStorageClass,fortranType,fortranProgram,fortranModule,fortranSubroutine,fortranFunction,fortranBlockData | |
406 syn region fortranIfBlock transparent fold keepend extend start="\(\<e\(nd\|lse\)\s\+\)\@<!\<if\s*(.\+)\s*then\>" skip="^\([!c*]\|\s*#\).*$" end="\<end\s*if\>" contains=ALLBUT,fortranUnitHeader,fortranStructure,fortranStorageClass,fortranType,fortranProgram,fortranModule,fortranSubroutine,fortranFunction,fortranBlockData | |
407 syn region fortranCase transparent fold keepend extend start="\<select\s*case\>" skip="^\([!c*]\|\s*#\).*$" end="\<end\s*select\>" contains=ALLBUT,fortranUnitHeader,fortranStructure,fortranStorageClass,fortranType,fortranProgram,fortranModule,fortranSubroutine,fortranFunction,fortranBlockData | |
408 else | |
409 syn region fortran77Loop transparent fold keepend start="\<do\s\+\z(\d\+\)" end="^\s*\z1\>" contains=ALLBUT,fortranUnitHeader,fortranStructure,fortranStorageClass,fortranType,fortranProgram,fortranModule,fortranSubroutine,fortranFunction,fortranBlockData | |
410 syn region fortran90Loop transparent fold keepend extend start="\(\<end\s\+\)\@<!\<do\(\s\+\a\|\s*$\)" skip="^\s*[!#].*$" excludenl end="\<end\s*do\>" contains=ALLBUT,fortranUnitHeader,fortranStructure,fortranStorageClass,fortranType,fortranProgram,fortranModule,fortranSubroutine,fortranFunction,fortranBlockData | |
8303
88207f4b861a
commit https://github.com/vim/vim/commit/dae8d21dd291df6a6679a00be64e18bca0156576
Christian Brabandt <cb@256bit.org>
parents:
7384
diff
changeset
|
411 syn region fortranIfBlock transparent fold keepend extend start="\(\<e\(nd\|lse\)\s\+\)\@<!\<if\s*(\(.\|&\s*\n\)\+)\(\s\|&\s*\n\)*then\>" skip="^\s*[!#].*$" end="\<end\s*if\>" contains=ALLBUT,fortranUnitHeader,fortranStructure,fortranStorageClass,fortranType,fortranProgram,fortranModule,fortranSubroutine,fortranFunction,fortranBlockData |
7 | 412 syn region fortranCase transparent fold keepend extend start="\<select\s*case\>" skip="^\s*[!#].*$" end="\<end\s*select\>" contains=ALLBUT,fortranUnitHeader,fortranStructure,fortranStorageClass,fortranType,fortranProgram,fortranModule,fortranSubroutine,fortranFunction,fortranBlockData |
413 endif | |
414 endif | |
415 | |
416 if exists("fortran_fold_multilinecomments") | |
417 if (b:fortran_fixed_source == 1) | |
418 syn match fortranMultiLineComments transparent fold "\(^[!c*].*\(\n\|\%$\)\)\{4,}" contains=ALLBUT,fortranMultiCommentLines | |
419 else | |
420 syn match fortranMultiLineComments transparent fold "\(^\s*!.*\(\n\|\%$\)\)\{4,}" contains=ALLBUT,fortranMultiCommentLines | |
421 endif | |
422 endif | |
423 endif | |
424 | |
425 " Define the default highlighting. | |
3281 | 426 " The default highlighting differs for each dialect. |
427 " Transparent groups: | |
428 " fortranParen, fortranLeftMargin | |
429 " fortranProgram, fortranModule, fortranSubroutine, fortranFunction, | |
430 " fortranBlockData | |
431 " fortran77Loop, fortran90Loop, fortranIfBlock, fortranCase | |
432 " fortranMultiCommentLines | |
433 hi def link fortranKeyword Keyword | |
434 hi def link fortranConstructName Identifier | |
435 hi def link fortranConditional Conditional | |
436 hi def link fortranRepeat Repeat | |
437 hi def link fortranTodo Todo | |
438 hi def link fortranContinueMark Special | |
439 hi def link fortranString String | |
440 hi def link fortranNumber Number | |
441 hi def link fortranOperator Operator | |
442 hi def link fortranBoolean Boolean | |
443 hi def link fortranLabelError Error | |
444 hi def link fortranObsolete Todo | |
445 hi def link fortranType Type | |
446 hi def link fortranStructure Type | |
447 hi def link fortranStorageClass StorageClass | |
448 hi def link fortranCall Function | |
449 hi def link fortranUnitHeader fortranPreCondit | |
450 hi def link fortranReadWrite Keyword | |
451 hi def link fortranIO Keyword | |
452 hi def link fortranIntrinsic Function | |
453 hi def link fortranConstant Constant | |
7 | 454 |
3281 | 455 " To stop deleted & obsolescent features being highlighted as Todo items, |
456 " comment out the next 5 lines and uncomment the 5 lines after that | |
457 hi def link fortranUnitHeaderOb fortranObsolete | |
458 hi def link fortranKeywordOb fortranObsolete | |
459 hi def link fortranConditionalOb fortranObsolete | |
460 hi def link fortranTypeOb fortranObsolete | |
461 hi def link fortranKeywordDel fortranObsolete | |
462 "hi def link fortranUnitHeaderOb fortranUnitHeader | |
463 "hi def link fortranKeywordOb fortranKeyword | |
464 "hi def link fortranConditionalOb fortranConditional | |
465 "hi def link fortranTypeOb fortranType | |
466 "hi def link fortranKeywordDel fortranKeyword | |
3256 | 467 |
3281 | 468 if b:fortran_dialect == "F" |
469 hi! def link fortranIntrinsicR fortranObsolete | |
470 hi! def link fortranUnitHeaderR fortranObsolete | |
471 hi! def link fortranTypeR fortranObsolete | |
472 hi! def link fortranStorageClassR fortranObsolete | |
473 hi! def link fortranOperatorR fortranObsolete | |
474 hi! def link fortranInclude fortranObsolete | |
475 hi! def link fortranLabelNumber fortranObsolete | |
476 hi! def link fortranTarget fortranObsolete | |
477 hi! def link fortranFloatIll fortranObsolete | |
478 hi! def link fortranIOR fortranObsolete | |
479 hi! def link fortranKeywordR fortranObsolete | |
480 hi! def link fortranStringR fortranObsolete | |
481 hi! def link fortranConditionalR fortranObsolete | |
482 else | |
483 hi! def link fortranIntrinsicR fortranIntrinsic | |
484 hi! def link fortranUnitHeaderR fortranPreCondit | |
485 hi! def link fortranTypeR fortranType | |
486 hi! def link fortranStorageClassR fortranStorageClass | |
487 hi! def link fortranOperatorR fortranOperator | |
488 hi! def link fortranInclude Include | |
489 hi! def link fortranLabelNumber Special | |
490 hi! def link fortranTarget Special | |
491 hi! def link fortranFloatIll fortranFloat | |
492 hi! def link fortranIOR fortranIO | |
493 hi! def link fortranKeywordR fortranKeyword | |
494 hi! def link fortranStringR fortranString | |
495 hi! def link fortranConditionalR fortranConditional | |
496 endif | |
7 | 497 |
6530 | 498 " CUDA |
499 hi def link fortranIntrinsicCUDA fortranIntrinsic | |
500 hi def link fortranTypeCUDA fortranType | |
501 hi def link fortranStringCUDA fortranString | |
502 | |
3281 | 503 hi def link fortranFormatSpec Identifier |
504 hi def link fortranFloat Float | |
505 hi def link fortranPreCondit PreCondit | |
506 hi def link cIncluded fortranString | |
507 hi def link cInclude Include | |
508 hi def link cPreProc PreProc | |
509 hi def link cPreCondit PreCondit | |
510 hi def link fortranParenError Error | |
511 hi def link fortranComment Comment | |
512 hi def link fortranSerialNumber Todo | |
513 hi def link fortranTab Error | |
7 | 514 |
3281 | 515 " Uncomment the next line if you use extra intrinsics provided by vendors |
516 "hi def link fortranExtraIntrinsic Function | |
7 | 517 |
518 let b:current_syntax = "fortran" | |
519 | |
3237 | 520 let &cpo = s:cpo_save |
521 unlet s:cpo_save | |
7 | 522 " vim: ts=8 tw=132 |