summaryrefslogtreecommitdiffstats
path: root/kate/data/haskell.xml
blob: 104e43ddafb2e7ca5ccc84fcf8344267e3148e05 (plain)
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
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE language SYSTEM "language.dtd">
<language name="Haskell" version="2.4" kateversion="2.3" section="Sources" extensions="*.hs;*.chs" mimetype="text/x-haskell" author="Nicolas Wu (zenzike@gmail.com)" license="LGPL" indenter="haskell" style="haskell">
  <highlighting>
  <list name="keywords">
    <item> case </item>
    <item> class </item>
    <item> data </item>
    <item> deriving </item>
    <item> do </item>
    <item> else </item>
    <item> if </item>
    <item> in </item>
    <item> infixl </item>
    <item> infixr </item>
    <item> instance </item>
    <item> let </item>
    <item> module </item>
    <item> newtype </item>
    <item> of </item>
    <item> primitive </item>
    <item> then </item>
    <item> type </item>
    <item> where </item>
  </list>
  <list name="prelude function">
    <item> FilePath </item>
    <item> IOError </item>
    <item> abs </item>
    <item> acos </item>
    <item> acosh </item>
    <item> all </item>
    <item> and </item>
    <item> any </item>
    <item> appendFile </item>
    <item> approxRational </item>
    <item> asTypeOf </item>
    <item> asin </item>
    <item> asinh </item>
    <item> atan </item>
    <item> atan2 </item>
    <item> atanh </item>
    <item> basicIORun </item>
    <item> break </item>
    <item> catch </item>
    <item> ceiling </item>
    <item> chr </item>
    <item> compare </item>
    <item> concat </item>
    <item> concatMap </item>
    <item> const </item>
    <item> cos </item>
    <item> cosh </item>
    <item> curry </item>
    <item> cycle </item>
    <item> decodeFloat </item>
    <item> denominator </item>
    <item> digitToInt </item>
    <item> div </item>
    <item> divMod </item>
    <item> drop </item>
    <item> dropWhile </item>
    <item> either </item>
    <item> elem </item>
    <item> encodeFloat </item>
    <item> enumFrom </item>
    <item> enumFromThen </item>
    <item> enumFromThenTo </item>
    <item> enumFromTo </item>
    <item> error </item>
    <item> even </item>
    <item> exp </item>
    <item> exponent </item>
    <item> fail </item>
    <item> filter </item>
    <item> flip </item>
    <item> floatDigits </item>
    <item> floatRadix </item>
    <item> floatRange </item>
    <item> floor </item>
    <item> fmap </item>
    <item> foldl </item>
    <item> foldl1 </item>
    <item> foldr </item>
    <item> foldr1 </item>
    <item> fromDouble </item>
    <item> fromEnum </item>
    <item> fromInt </item>
    <item> fromInteger </item>
    <item> fromIntegral </item>
    <item> fromRational </item>
    <item> fst </item>
    <item> gcd </item>
    <item> getChar </item>
    <item> getContents </item>
    <item> getLine </item>
    <item> group </item>
    <item> head </item>
    <item> id </item>
    <item> inRange </item>
    <item> index </item>
    <item> init </item>
    <item> intToDigit </item>
    <item> interact </item>
    <item> ioError </item>
    <item> isAlpha </item>
    <item> isAlphaNum </item>
    <item> isAscii </item>
    <item> isControl </item>
    <item> isDenormalized </item>
    <item> isDigit </item>
    <item> isHexDigit </item>
    <item> isIEEE </item>
    <item> isInfinite </item>
    <item> isLower </item>
    <item> isNaN </item>
    <item> isNegativeZero </item>
    <item> isOctDigit </item>
    <item> isPrint </item>
    <item> isSpace </item>
    <item> isUpper </item>
    <item> iterate </item>
    <item> last </item>
    <item> lcm </item>
    <item> length </item>
    <item> lex </item>
    <item> lexDigits </item>
    <item> lexLitChar </item>
    <item> lines </item>
    <item> log </item>
    <item> logBase </item>
    <item> lookup </item>
    <item> map </item>
    <item> mapM </item>
    <item> mapM_ </item>
    <item> max </item>
    <item> maxBound </item>
    <item> maximum </item>
    <item> maybe </item>
    <item> min </item>
    <item> minBound </item>
    <item> minimum </item>
    <item> mod </item>
    <item> negate </item>
    <item> not </item>
    <item> notElem </item>
    <item> null </item>
    <item> numerator </item>
    <item> odd </item>
    <item> or </item>
    <item> ord </item>
    <item> otherwise </item>
    <item> pack </item>
    <item> pi </item>
    <item> pred </item>
    <item> primExitWith </item>
    <item> print </item>
    <item> product </item>
    <item> properFraction </item>
    <item> putChar </item>
    <item> putStr </item>
    <item> putStrLn </item>
    <item> quot </item>
    <item> quotRem </item>
    <item> range </item>
    <item> rangeSize </item>
    <item> read </item>
    <item> readDec </item>
    <item> readFile </item>
    <item> readFloat </item>
    <item> readHex </item>
    <item> readIO </item>
    <item> readInt </item>
    <item> readList </item>
    <item> readLitChar </item>
    <item> readLn </item>
    <item> readOct </item>
    <item> readParen </item>
    <item> readSigned </item>
    <item> reads </item>
    <item> readsPrec </item>
    <item> realToFrac </item>
    <item> recip </item>
    <item> rem </item>
    <item> repeat </item>
    <item> replicate </item>
    <item> return </item>
    <item> reverse </item>
    <item> round </item>
    <item> scaleFloat </item>
    <item> scanl </item>
    <item> scanl1 </item>
    <item> scanr </item>
    <item> scanr1 </item>
    <item> seq </item>
    <item> sequence </item>
    <item> sequence_ </item>
    <item> show </item>
    <item> showChar </item>
    <item> showInt </item>
    <item> showList </item>
    <item> showLitChar </item>
    <item> showParen </item>
    <item> showSigned </item>
    <item> showString </item>
    <item> shows </item>
    <item> showsPrec </item>
    <item> significand </item>
    <item> signum </item>
    <item> sin </item>
    <item> sinh </item>
    <item> snd </item>
    <item> sort </item>
    <item> span </item>
    <item> splitAt </item>
    <item> sqrt </item>
    <item> subtract </item>
    <item> succ </item>
    <item> sum </item>
    <item> tail </item>
    <item> take </item>
    <item> takeWhile </item>
    <item> tan </item>
    <item> tanh </item>
    <item> threadToIOResult </item>
    <item> toEnum </item>
    <item> toInt </item>
    <item> toInteger </item>
    <item> toLower </item>
    <item> toRational </item>
    <item> toUpper </item>
    <item> truncate </item>
    <item> uncurry </item>
    <item> undefined </item>
    <item> unlines </item>
    <item> until </item>
    <item> unwords </item>
    <item> unzip </item>
    <item> unzip3 </item>
    <item> userError </item>
    <item> words </item>
    <item> writeFile </item>
    <item> zip </item>
    <item> zip3 </item>
    <item> zipWith </item>
    <item> zipWith3 </item>
  </list>
  <list name="prelude class">
    <item> Bounded </item>
    <item> Enum </item>
    <item> Eq </item>
    <item> Floating </item>
    <item> Fractional </item>
    <item> Functor </item>
    <item> Integral </item>
    <item> Ix </item>
    <item> Monad </item>
    <item> Num </item>
    <item> Ord </item>
    <item> Read </item>
    <item> Real </item>
    <item> RealFloat </item>
    <item> RealFrac </item>
    <item> Show </item>
  </list>
  <list name="prelude type">
    <item> Bool </item>
    <item> Char </item>
    <item> Double </item>
    <item> Either </item>
    <item> FilePath </item>
    <item> Float </item>
    <item> Int </item>
    <item> Integer </item>
    <item> IO </item>
    <item> IOError </item>
    <item> Maybe </item>
    <item> Ordering </item>
    <item> Ratio </item>
    <item> Rational </item>
    <item> ReadS </item>
    <item> ShowS </item>
    <item> String </item>
    <item> ByteString </item>
  </list>
  <list name="prelude data">
    <item> False </item>
    <item> True </item>
    <item> Left </item>
    <item> Right </item>
    <item> Just </item>
    <item> Nothing </item>
    <item> EQ </item>
    <item> LT </item>
    <item> GT </item>
  </list>
  <list name="class">
    <item> Applicative </item>
    <item> Foldable </item>
    <item> Traversable </item>
  </list>
  <list name="c2hs_keywords">
    <item> qualified </item>
    <item> lib </item>
    <item> prefix </item>
    <item> as </item>
    <item> with </item>
    <item> call </item>
    <item> pure </item>
    <item> unsafe </item>
    <item> get </item>
    <item> set </item>
    <item> foreign </item>
    <item> stable </item>
    <item> nocode </item>
  </list>
  <list name="import_keywords">
    <item> as </item>
    <item> qualified </item>
    <item> hiding </item>
  </list>
  <contexts>
    <context attribute="Normal" lineEndContext="#stay" name="code">
      <RegExpr attribute="Pragma"  context="#stay" String="\{-#.*#-\}"/>
      <RegExpr attribute="Comment" context="comments" String="\{-[^#]?" />
      <RegExpr attribute="Comment" context="comment"  String="--[^\-!#\$%&amp;\*\+/&lt;=&gt;\?&#92;@\^\|~\.:].*$" />
      <RegExpr attribute="Keyword" context="import"   String="import\s+" />
      <RegExpr attribute="C2HS Directive"  context="c2hs directive" String="\{#"/>
      <RegExpr attribute="C2HS Directive"  context="c2hs include" String="#"/>

      <keyword attribute="Keyword"          context="#stay" String="keywords" />
      <keyword attribute="Function Prelude" context="#stay" String="prelude function" />
      <keyword attribute="Type Prelude"     context="#stay" String="prelude type" />
      <keyword attribute="Data Prelude"     context="#stay" String="prelude data" />
      <keyword attribute="Class Prelude"    context="#stay" String="prelude class" />
      <keyword attribute="Class Prelude"    context="#stay" String="class" />

      <RegExpr attribute="Special"          context="#stay" String="(::|=&gt;|\-&gt;|&lt;\-)" />
      <AnyChar attribute="Special"          context="#stay" String="∷⇒→←∀∃" />
      <RegExpr attribute="Signature"        context="#stay" String="\s*[a-z][a-zA-Z0-9_']*\s*(?=::[^\-!#\$%&amp;\*\+/&lt;=&gt;\?&#92;@\^\|~\.:])" />
      <RegExpr attribute="Signature"        context="#stay" String="\s*(\([\-!#\$%&amp;\*\+/&lt;=&gt;\?&#92;@\^\|~\.:]*\))*\s*(?=::[^\-!#\$%&amp;\*\+/&lt;=&gt;\?&#92;@\^\|~\.:])" />
      <RegExpr attribute="Function"         context="#stay" String="([A-Z][a-zA-Z0-9_']*\.)*[a-z][a-zA-Z0-9_']*" />
      <RegExpr attribute="Operator"         context="#stay" String="([A-Z][a-zA-Z0-0_']*\.)*[\-!#\$%&amp;\*\+/&lt;=&gt;\?&#92;@\^\|~\.:]+" />
      <RegExpr attribute="Type"             context="#stay" String="([A-Z][a-zA-Z0-9_']*\.)*[A-Z][a-zA-Z0-9_']*" />

      <RegExpr    attribute="Float"   context="#stay" String ="\d+\.\d+([Ee][+-]?\d+)?|\d+[Ee][+-]?\d+"/>
      <RegExpr    attribute="Octal"   context="#stay" String="0[Oo][0-7]+"/>
      <RegExpr    attribute="Hex"     context="#stay" String="0[Xx][0-9A-Fa-f]+"/>
      <Int        attribute="Decimal" context="#stay" />
      <DetectChar attribute="Char"    context="char" char="'" />
      <DetectChar attribute="String"  context="string" char="&quot;" />

      <DetectChar attribute="Function Infix" context="infix" char="`"/>
      <Detect2Chars attribute="EnumFromTo" context="#stay" char ="." char1="." />
      <AnyChar      attribute="EnumFromTo" context="#stay" String="‥" />
    </context>
    <context attribute="Comment" lineEndContext="#pop" name="comment" />
    <context attribute="Comment" lineEndContext="#stay" name="comments">
      <Detect2Chars attribute="Comment" context="#pop" char="-" char1="}" />
    </context>
    <context attribute="Char" lineEndContext="#pop" name="char">
      <RegExpr attribute="Char" context="#stay" String="\\." />
      <DetectChar attribute="Char" context="#pop" char="'" />
    </context>
    <context attribute="String" lineEndContext="#stay" name="string">
      <RegExpr attribute="String" context="#stay" String="\\." />
      <DetectChar attribute="String" context="#pop" char="&quot;" />
    </context>
    <context attribute="Function Infix" lineEndContext="#stay" name="infix">
      <DetectChar attribute="Function Infix" context="#pop" char="`"/>
    </context>
    <context attribute="Import Statement" lineEndContext="#pop" name="import">
      <keyword attribute="Keyword"          context="#stay" String="import_keywords" />
      <RegExpr attribute="Function"         context="#stay" String="([A-Z][a-zA-Z0-9_']*\.)*[a-z][a-zA-Z0-9_']*" />
      <RegExpr attribute="Type"             context="#stay" String="([A-Z][a-zA-Z0-9_']*\.)*[A-Z][a-zA-Z0-9_']*" />

      <RegExpr attribute="Pragma"  context="#stay" String="\{-#.*#-\}"/>
      <RegExpr attribute="Comment" context="comments" String="\{-[^#]?" />
      <RegExpr attribute="Comment" context="comment"  String="--[^\-!#\$%&amp;\*\+/&lt;=&gt;\?&#92;@\^\|~\.:].*$" />
    </context>
    
    <context attribute="C2HS Directive" lineEndContext="#stay" name="c2hs directive">
      <Detect2Chars attribute="C2HS Directive" context="#pop" char="#" char1="}" />
      <keyword attribute="Keyword" context="#stay"          String="c2hs_keywords" />
      <RegExpr attribute="Keyword" context="#stay"          String="context" />
      <RegExpr attribute="Keyword" context="#stay"          String="call" />
      <RegExpr attribute="Keyword" context="#stay"          String="sizeof" />
      <RegExpr attribute="Keyword" context="#stay"          String="alignof" />
      <RegExpr attribute="Keyword" context="c2hs fun"       String="fun" />
      <RegExpr attribute="Keyword" context="c2hs pointer"   String="pointer" />
      <RegExpr attribute="Keyword" context="c2hs enum"      String="enum" />
      <RegExpr attribute="Keyword" context="c2hs import"    String="import" />
    </context>
    <context attribute="C2HS Directive" lineEndContext="#stay" name="c2hs import">
      <RegExpr attribute="Type"    context="#stay" String="([A-Z][a-zA-Z0-9_']*\.)*[A-Z][a-zA-Z0-9_']*" />
      <Detect2Chars attribute="C2HS Directive" context="#pop#pop" char="#" char1="}" />
    </context>
    <context attribute="C2HS Directive" lineEndContext="#pop" name="c2hs include">
      <RegExpr attribute="Keyword" context="#stay" String="include" />
      <RegExpr                     context="#stay" String="*.>$" />
    </context>
    <context attribute="C2HS Directive" lineEndContext="#stay" name="c2hs pointer">
      <keyword attribute="Keyword" context="#stay" String="c2hs_keywords" />
      <RegExpr attribute="Keyword" context="#stay" String="newtype" />
      <RegExpr attribute="Type"    context="#stay" String="([A-Z][a-zA-Z0-9_']*\.)*[A-Z][a-zA-Z0-9_']*" />
      <Detect2Chars attribute="C2HS Directive" context="#pop#pop" char="#" char1="}" />
    </context>
    <context attribute="C2HS Directive" lineEndContext="#stay" name="c2hs fun">
      <keyword attribute="Keyword" context="#stay" String="c2hs_keywords" />
      <RegExpr attribute="Type" context="#stay" String="`[^']*'" />
      <Detect2Chars attribute="C2HS Directive" context="#pop#pop" char="#" char1="}" />
    </context>
    <context attribute="C2HS Directive" lineEndContext="#stay" name="c2hs enum">
      <RegExpr attribute="Type"             context="#stay" String="([A-Z][a-zA-Z0-9_']*\.)*[A-Z][a-zA-Z0-9_']*" />
      <Detect2Chars attribute="C2HS Directive" context="#pop#pop" char="#" char1="}" />
    </context>
  </contexts>
  <itemDatas>
    <itemData name="Normal"           defStyleNum="dsNormal"   spellChecking="false" />
    <itemData name="Comment"          defStyleNum="dsComment" />
    <itemData name="Pragma"           defStyleNum="dsOthers"   spellChecking="false" />

    <itemData name="Keyword"          defStyleNum="dsKeyword"  spellChecking="false" />
    <itemData name="Type Prelude"     defStyleNum="dsDataType" spellChecking="false" />
    <itemData name="Function Prelude" defStyleNum="dsFunction" spellChecking="false" />
    <itemData name="Data Prelude"     defStyleNum="dsKeyword"  spellChecking="false" />
    <itemData name="Class Prelude"    defStyleNum="dsKeyword"  spellChecking="false" />

    <itemData name="Signature"        defStyleNum="dsOthers"  spellChecking="false" />
    <itemData name="Function"         defStyleNum="dsNormal"   spellChecking="false" />
    <itemData name="Operator"         defStyleNum="dsFunction" spellChecking="false" />
    <itemData name="Type"             defStyleNum="dsDataType" spellChecking="false" />
    <itemData name="Special"          defStyleNum="dsOthers"  spellChecking="false" />

    <itemData name="Octal"            defStyleNum="dsBaseN"    spellChecking="false" />
    <itemData name="Hex"              defStyleNum="dsBaseN"    spellChecking="false" />
    <itemData name="Decimal"          defStyleNum="dsDecVal"   spellChecking="false" />
    <itemData name="Float"            defStyleNum="dsFloat"    spellChecking="false" />
    <itemData name="Char"             defStyleNum="dsChar"     spellChecking="false" />
    <itemData name="String"           defStyleNum="dsString" />

    <itemData name="Function Infix"   defStyleNum="dsOthers"   spellChecking="false" />
    <itemData name="EnumFromTo"       defStyleNum="dsOthers"   spellChecking="false" />
    
    <itemData name="C2HS Directive"   defStyleNum="dsString"   spellChecking="false" />
  </itemDatas>
  </highlighting>
  <general>
    <folding indentationsensitive="1"/>
    <comments>
      <comment name="singleLine" start="--" />
      <comment name="multiLine" start="{-" end="-}" />
    </comments>
    <keywords casesensitive="1" />
</general>
</language>