@@ -1,9 +1,9 @@
11<?xml version="1.0" encoding="UTF-8"?>
22<syntax name="haskell">
33 <meta>
4− <name>Haskell</name>
5− <type>compiled</type>
6− <preferred-file-extension>hs</preferred-file-extension>
4+ <name>Haskell</name>
5+ <type>compiled</type>
6+ <preferred-file-extension>hs</preferred-file-extension>
77 </meta>
88
99 <detectors>
@@ -57,8 +57,6 @@
5757 <include syntax="self" collection="type-family-definition" />
5858 <include syntax="self" collection="pattern-definition" />
5959 <include syntax="self" collection="type-definition" />
60− <!-- <include syntax="self" collection="type-annotation" /> -->
61− <include syntax="self" collection="data-definition" />
6260 <include syntax="self" collection="GADT-definition" />
6361 <include syntax="self" collection="instance" />
6462 <include syntax="self" collection="typeclass" />
@@ -67,7 +65,6 @@
6765
6866 <template-scopes>
6967 <include syntax="self" collection="Quote" />
70− <include syntax="self" collection="comments" />
7168 </template-scopes>
7269
7370 <collections>
@@ -80,51 +77,27 @@
8077 </collection>
8178
8279 <collection name="expressions">
83− <include syntax="self" collection="do-bind" />
80+ <scope name="haskell.construct.keyword.at">
81+ <expression>@</expression>
82+ </scope>
83+ <scope name="haskell.construct.keyword.case-arrow">
84+ <expression>-></expression>
85+ </scope>
86+ <scope name="haskell.construct.keyword.bind-arrow">
87+ <expression><-</expression>
88+ </scope>
89+ <include syntax="self" collection="keywords" />
8490 <include syntax="self" collection="literal" />
8591 <include syntax="self" collection="operators" />
92+ <include syntax="self" collection="record-match" />
8693 <include syntax="self" collection="list" />
94+ <include syntax="self" collection="view-pattern" />
8795 <include syntax="self" collection="lambda-case" />
8896 <include syntax="self" collection="lambda-head" />
89− <include syntax="self" collection="type-applications" />
90− <include syntax="self" collection="outer-case-expression" />
97+ <include syntax="self" collection="case-expression" />
98+ <include syntax="self" collection="qconid" />
9199 <include syntax="self" collection="qvarid" />
92100 <include syntax="self" collection="tuple" />
93−
94−
95− <!-- Needed for do binds -->
96− <!-- <include syntax="self" collection="pattern-match" /> -->
97− </collection>
98−
99− <collection name="pattern-match">
100− <include syntax="self" collection="literal" />
101− <include syntax="self" collection="tuple-match" />
102− <!-- <include syntax="self" collection="at-pattern" /> -->
103− <include syntax="self" collection="varid" />
104− <include syntax="self" collection="qconid" />
105− <include syntax="self" collection="record-match" />
106− <include syntax="self" collection="list-pattern" />
107− <include syntax="self" collection="view-pattern" />
108− </collection>
109−
110− <collection name="type-applications">
111− <scope name="type-applications">
112− <starts-with>
113− <expression>(\s@)\(</expression>
114− <capture number="1" name="haskell.keyword.operator.typeapplication" />
115− </starts-with>
116− <ends-with>
117− <expression>)</expression>
118− </ends-with>
119− <subscopes>
120− <include syntax="self" collection="type" />
121− </subscopes>
122− </scope>
123− <scope name="type-applications-single">
124− <expression>(@)(\w+)</expression>
125− <capture number="1" name="haskell.keyword.operator.typeapplication" />
126− <capture number="2" name="haskell.identifier.type" />
127− </scope>
128101 </collection>
129102
130103 <collection name="Quote">
@@ -163,8 +136,8 @@
163136 <capture number="1" name="haskell.pattern.record.bracket" />
164137 </ends-with>
165138 <subscopes>
166− <include syntax="self" collection="pattern-match" />
167− <include syntax="self" collection="varid" />
139+ <include syntax="self" collection="comments" />
140+ <include syntax="self" collection="expressions" />
168141 <scope name="record-sep">
169142 <expression>=</expression>
170143 </scope>
@@ -186,6 +159,7 @@
186159 <capture number="1" name="haskell.pattern.record.bracket" />
187160 </ends-with>
188161 <subscopes>
162+ <include syntax="self" collection="comments" />
189163 <scope name="haskell.pattern.record.wildcard">
190164 <expression>\.\.</expression>
191165 </scope>
@@ -212,29 +186,12 @@
212186 <capture number="1" name="haskell.list.bracket" />
213187 </ends-with>
214188 <subscopes>
189+ <include syntax="self" collection="comments" />
215190 <include syntax="self" collection="expressions" />
216191 </subscopes>
217192 </scope>
218193 </collection>
219194
220− <collection name="list-pattern">
221− <symbol type="expression" />
222− <scope name="haskell.pattern.list">
223− <starts-with>
224− <expression>(\[)</expression>
225− <capture number="1" name="haskell.pattern.list.bracket" />
226− </starts-with>
227− <ends-with>
228− <expression>(\])</expression>
229− <capture number="1" name="haskell.pattern.list.bracket" />
230− </ends-with>
231− <subscopes>
232− <include syntax="self" collection="pattern-match" />
233− </subscopes>
234− </scope>
235− </collection>
236−
237−
238195 <collection name="view-pattern">
239196 <scope name="haskell.pattern.view">
240197 <symbol type="expression" />
@@ -251,24 +208,7 @@
251208 <scope name="haskell.pattern.view.operator.arrow">
252209 <expression>-></expression>
253210 </scope>
254− <include syntax="self" collection="pattern-match" />
255− </subscopes>
256− </scope>
257− </collection>
258−
259− <collection name="tuple-match">
260− <symbol type="expression" />
261− <scope name="haskell.pattern.tuple">
262− <starts-with>
263− <expression>(\()</expression>
264− <capture number="1" name="haskell.pattern.tuple.bracket" />
265− </starts-with>
266− <ends-with>
267− <expression>(\))</expression>
268− <capture number="1" name="haskell.pattern.tuple.bracket" />
269− </ends-with>
270− <subscopes>
271− <include syntax="self" collection="pattern-match" />
211+ <include syntax="self" collection="expressions" />
272212 </subscopes>
273213 </scope>
274214 </collection>
@@ -284,53 +224,11 @@
284224 <capture number="1" name="haskell.case.keyword.condition" />
285225 </ends-with>
286226 <subscopes anchored="true">
287− <include syntax="self" collection="pattern-match" />
288− </subscopes>
289− </scope>
290− </collection>
291−
292− <collection name="case-match">
293− <scope name="case-match">
294− <starts-with>
295− <expression>(?=((\h*)\S.*->($|\h)))</expression>
296− </starts-with>
297− <ends-with>
298− <expression>-></expression>
299− </ends-with>
300− <subscopes anchored="true">
301− <include syntax="self" collection="pattern-match" />
302− </subscopes>
303− </scope>
304− </collection>
305−
306− <collection name="inner-case-expressions">
307− <scope name="inner-case-expressions">
308− <starts-with>
309− <expression>(?=((\h*)\S.*->($|\h)))</expression>
310− </starts-with>
311− <ends-with>
312− <template>^(?!\1)(?!\2\h)(?!\s*$)</template>
313− </ends-with>
314− <subscopes>
315− <include syntax="self" collection="case-match" />
316227 <include syntax="self" collection="expressions" />
317228 </subscopes>
318229 </scope>
319230 </collection>
320231
321− <collection name="outer-case-expression">
322− <scope name="outer-case-expression">
323− <starts-with>
324− <expression>(?=case)</expression>
325− </starts-with>
326− <ends-with />
327− <subscopes anchored="true" skip-whitespace="false">
328− <include syntax="self" collection="case-expression" />
329− <include syntax="self" collection="inner-case-expressions" repeat="true" />
330− </subscopes>
331− </scope>
332− </collection>
333−
334232 <collection name="tuple">
335233 <symbol type="expression" />
336234 <scope name="haskell.tuple">
@@ -343,60 +241,73 @@
343241 <capture number="1" name="haskell.tuple.bracket" />
344242 </ends-with>
345243 <subscopes>
244+ <include syntax="self" collection="comments" />
346245 <include syntax="self" collection="expressions" />
347246 </subscopes>
348247 </scope>
349248 </collection>
350249
351250 <collection name="typeclass">
352− <symbol type="interface" />
353− <scope name="haskell.definition.class">
251+ <scope name="haskell.definition.class.head">
252+ <symbol type="class" scope="global" name-selector="haskell.keyword.construct.class.name">
253+ <context behavior="whitespace" foldable="true" />
254+ </symbol>
354255 <starts-with>
355256 <expression>^(\h*)(class)($|\h)</expression>
356257 <capture number="2" name="haskell.keyword.construct.class" />
357258 </starts-with>
358− <ends-with>
359− <template>^(?!\s+\1\S)(?!\s*$)</template>
360− </ends-with>
361− <subscopes>
362− <scope name="haskell.keyword.construct.where">
259+ <ends-with />
260+ <subscopes anchored="true">
261+ <scope name="haskell.keyword.construct.class.name">
262+ <starts-with>
263+ <expression></expression>
264+ </starts-with>
265+ <ends-with>
266+ <expression>(?=(where|^\s*$))</expression>
267+ </ends-with>
268+ <subscopes>
269+ <include syntax="self" collection="comments" />
270+ <include syntax="self" collection="type" />
271+ </subscopes>
272+ </scope>
273+ <scope name="haskell.keyword.construct.where" optional="true">
363274 <expression>where</expression>
364275 </scope>
365− <include syntax="self" collection="type" />
366− <include syntax="self" collection="type-definition" />
367− <!-- <include syntax="self" collection="type-annotation" /> -->
368− <include syntax="self" collection="definition" />
369276 </subscopes>
370277 </scope>
371278 </collection>
372279
373280 <collection name="instance">
374281 <scope name="haskell.instance">
375− <symbol type="category" />
282+ <symbol type="category" name-selector="haskell.keyword.construct.instance.name">
283+ <context behavior="whitespace" foldable="true" />
284+ </symbol>
376285 <starts-with>
377286 <expression>^(\h*)(instance)($|\h)</expression>
378287 <capture number="2" name="haskell.keyword.construct.instance" />
379288 </starts-with>
380− <ends-with>
381− <template>^(?!\s+\1\S)(?!\s*$)</template>
382− </ends-with>
383− <subscopes>
384− <scope name="haskell.keyword.construct.where">
289+ <ends-with />
290+ <subscopes anchored="true">
291+ <scope name="haskell.keyword.construct.instance.name">
292+ <starts-with>
293+ <expression></expression>
294+ </starts-with>
295+ <ends-with>
296+ <expression>(?=(where|^\s*$))</expression>
297+ </ends-with>
298+ <subscopes>
299+ <include syntax="self" collection="type" />
300+ </subscopes>
301+ </scope>
302+ <scope name="haskell.keyword.construct.where" optional="true">
385303 <expression>where</expression>
386304 </scope>
387− <include syntax="self" collection="type" />
388− <include syntax="self" collection="type-definition" />
389− <include syntax="self" collection="type-annotation" />
390− <include syntax="self" collection="definition" />
391305 </subscopes>
392306 </scope>
393307 </collection>
394308
395309 <collection name="type-family-definition">
396310 <scope name="haskell.definition.type-family.type">
397− <symbol type="type">
398− <context behavior="subtree" foldable="false" />
399− </symbol>
400311 <starts-with>
401312 <expression>^(\h*)(type\h+family)</expression>
402313 <capture number="2" name="haskell.keyword.construct.type-family" />
@@ -435,6 +346,7 @@
435346 <template>^(?!\s+\1\S)(?!\s*$)</template>
436347 </ends-with>
437348 <subscopes>
349+ <include syntax="self" collection="comments" />
438350 <include syntax="self" collection="type" optional="true" repeat="true" />
439351 <scope>
440352 <expression>=</expression>
@@ -447,65 +359,26 @@
447359 <collection name="definition">
448360 <scope name="haskell.definition.type.function">
449361 <symbol type="function">
450− <display-name>
451− <component selector="haskell.definition.type.function" />
452− </display-name>
453−
362+ <context behavior="whitespace" foldable="true" />
454363 </symbol>
455364 <starts-with>
456365 <expression>^(?=(\h*)(default\h+)?`?(\w(\w|')*)`?($|\h))</expression>
457366 <capture number="2" name="haskell.keyword.construct.default" />
458− <capture number="3" name="haskell.identifier.function" />
367+ <capture number="3" name="haskell.identifier.function.name" />
459368 </starts-with>
460369 <ends-with>
461370 <template>^(?!\1\3\s)(?!\s+\1\S)(?!\s*$)</template>
462371 </ends-with>
463372 <subscopes>
373+ <include syntax="self" collection="comments" />
464374 <include syntax="self" collection="type-annotation" />
465375 <include syntax="self" collection="implementation" />
466376 </subscopes>
467377 </scope>
468378 </collection>
469379
470− <collection name="do-bind">
471− <scope name="do-bind">
472− <starts-with>
473− <expression>^(?=((\h*)\S.+<-($|\h)))</expression>
474− </starts-with>
475− <ends-with>
476− <template>^(?!\1)(?!\2\h)(?!\s*$)</template>
477− </ends-with>
478− <subscopes>
479− <include syntax="self" collection="do-pattern" />
480− <include syntax="self" collection="expressions" />
481− <!-- <scope name="bind-arrow">
482− <expression><-</expression>
483− </scope> -->
484− </subscopes>
485− </scope>
486− </collection>
487−
488− <collection name="do-pattern">
489− <scope name="do-pattern">
490− <starts-with>
491− <expression>^(?=((\h*)\S.+<-($|\h)))</expression>
492− </starts-with>
493− <ends-with>
494− <expression><-</expression>
495− </ends-with>
496− <subscopes>
497− <include syntax="self" collection="pattern-match" />
498− <!-- <scope name="bind-arrow">
499− <expression><-</expression>
500− </scope>
501− <include syntax="self" collection="expressions" repeat="true" /> -->
502− </subscopes>
503− </scope>
504− </collection>
505−
506380 <collection name="implementation">
507− <scope name="haskell.definition.type.function">
508− <local scope="within-construct" />
381+ <scope name="haskell.definition.type.function.implementation">
509382 <starts-with>
510383 <expression>^(\h*)(default\h+)?`?(\w(\w|')*)`?($|\h)</expression>
511384 <capture number="2" name="haskell.keyword.construct.default" />
@@ -515,14 +388,20 @@
515388 <template>^(?!\1\3\s)(?!\s+\1\S)(?!\s*$)</template>
516389 </ends-with>
517390 <subscopes>
518− <include syntax="self" collection="where-clause" />
519− <include syntax="self" collection="expressions" />
391+ <include syntax="self" collection="comments" />
392+ <include syntax="self" collection="pattern-match" optional="true" repeat="true" />
393+ <scope>
394+ <expression>=</expression>
395+ <capture number="0" name="haskell.construct.function.keyword.eq" />
396+ </scope>
397+ <include syntax="self" collection="expressions" optional="true" repeat="true" />
398+ <include syntax="self" collection="where-clause" optional="true" />
520399 </subscopes>
521400 </scope>
522401 </collection>
523402
524403 <collection name="type-annotation">
525− <scope name="haskell.definition.type.function">
404+ <scope name="haskell.definition.type.function.type-signature">
526405 <starts-with>
527406 <expression>^(\h*)`?(\w(\w|')*)`?\h*::($|\h)</expression>
528407 <capture number="2" name="haskell.identifier.function" />
@@ -531,6 +410,7 @@
531410 <template>^(?!\s+\1\S)(?!\s*$)</template>
532411 </ends-with>
533412 <subscopes>
413+ <include syntax="self" collection="comments" />
534414 <include syntax="self" collection="type" />
535415 </subscopes>
536416 </scope>
@@ -538,15 +418,19 @@
538418
539419 <collection name="type-definition">
540420 <scope name="haskell.definition.type">
421+ <symbol type="type" scope="global">
422+ <context behavior="whitespace" foldable="true" />
423+ </symbol>
541424 <starts-with>
542425 <expression>^(\h*)(type)\h+(\w(\w|')*)</expression>
543426 <capture number="2" name="haskell.keyword.construct.type" />
544− <capture number="3" name="haskell.identifier.type" />
427+ <capture number="3" name="haskell.identifier.type.name" />
545428 </starts-with>
546429 <ends-with>
547430 <template>^(?!\s+\1\S)(?!\s*$)</template>
548431 </ends-with>
549432 <subscopes>
433+ <include syntax="self" collection="comments" />
550434 <include syntax="self" collection="type" />
551435 </subscopes>
552436 </scope>
@@ -554,66 +438,72 @@
554438
555439 <collection name="GADT-definition">
556440 <scope name="haskell.definition.struct.GADT">
441+ <symbol type="struct" scope="global">
442+ <context behavior="subtree" foldable="false" />
443+ </symbol>
557444 <starts-with>
558− <expression>^(\h*)(data)\h+(\w(\w|')*)</expression>
445+ <expression>^(\h*)(data|newtype)\h+(\w(\w|')*)</expression>
559446 <capture number="2" name="haskell.keyword.construct.data.GADT" />
447+ <capture number="3" name="haskell.identifier.data.type.name" />
560448 </starts-with>
561449 <ends-with>
562450 <template>^(?!\s+\1\S)(?!\s*$)</template>
563451 </ends-with>
564452 <subscopes>
453+ <include syntax="self" collection="comments" />
454+ <scope name="haskell.keyword.construct.where">
455+ <expression>where</expression>
456+ </scope>
457+
458+ <include syntax="self" collection="deriving-clause" />
459+ <include syntax="self" collection="record-definition" />
565460 <include syntax="self" collection="gadt-constructor" />
566461 <include syntax="self" collection="type" />
567− <include syntax="self" collection="record-definition" />
568− <include syntax="self" collection="record-definition-field-name" />
569462 </subscopes>
570463 </scope>
571464 </collection>
572465
573466 <collection name="gadt-constructor">
574− <scope name="identifier.type.struct.GADT.constructor">
575− <expression>^\h+[A-Z](\w|')*</expression>
576− </scope>
577− </collection>
578−
579− <collection name="data-definition">
580− <scope name="haskell.definition.struct.data">
467+ <scope name="haskell.identifier.type.struct.data.constructor">
468+ <symbol type="constructor">
469+ <context behavior="subtree" foldable="true" />
470+ </symbol>
581471 <starts-with>
582− <expression>^(\h*)(data|newtype)\h+(\w(\w|')*)</expression>
583− <capture number="2" name="haskell.keyword.construct.data.newtype" />
584− <capture number="3" name="haskell.identifier.type" />
472+ <expression>(^|=|\||^)\h+([A-Z](\w|')*)</expression>
473+ <capture number="2" name="haskell.identifier.data.name" />
585474 </starts-with>
586− <ends-with>
587− <template>^(?!\s+\1\S)(?!\s*$)</template>
588− </ends-with>
589− <subscopes>
475+ <ends-with />
476+ <subscopes anchored="true">
590477 <include syntax="self" collection="record-definition" />
591− <include syntax="self" collection="data-constructor" />
592− <include syntax="self" collection="type" />
593478 </subscopes>
594479 </scope>
595480 </collection>
596481
597− <collection name="data-constructor">
598− <scope name="haskell.identifier.type.struct.data.constructor">
599− <expression>=\h+[A-Z](\w|')*</expression>
482+ <collection name="deriving-clause">
483+ <scope name="haskell.record.construct.deriving.keyword">
484+ <expression>deriving(\h+(newtype|stock|anyclass))?</expression>
600485 </scope>
601− <scope name="haskell.identifier.type.struct.data.constructor">
602− <expression>\|\h+[A-Z](\w|')*</expression>
486+ <scope name="haskell.record.construct.deriving.keyword">
487+ <include syntax="self" collection="comments" />
488+ <expression>via</expression>
603489 </scope>
604490 </collection>
605491
606492 <collection name="record-definition">
607493 <scope name="haskell.record">
494+ <symbol>
495+ <context behavior="subtree" foldable="true" />
496+ </symbol>
608497 <starts-with>
609− <expression>(\{)</expression>
610− <capture number="1" name="haskell.record.bracket" />
498+ <expression>(?=\{)</expression>
499+ <capture number="0" name="haskell.record.bracket" />
611500 </starts-with>
612501 <ends-with>
613502 <expression>(\})</expression>
614503 <capture number="1" name="haskell.record.bracket" />
615504 </ends-with>
616505 <subscopes>
506+ <include syntax="self" collection="comments" />
617507 <include syntax="self" collection="record-definition-field-name" />
618508 <include syntax="self" collection="type" />
619509 </subscopes>
@@ -622,11 +512,21 @@
622512
623513 <collection name="record-definition-field-name">
624514 <scope name="haskell.record.definition.property">
625− <expression>\w(\w|')*\h*::</expression>
515+ <symbol type="property" />
516+ <expression>(((?![A-Z])\w(\w|')*)\h*::|(^|\{|,)\h*((?![A-Z])\w(\w|')*))</expression>
517+ <capture number="5" name="haskell.record.definition.property.field.property.name" />
518+ <capture number="2" name="haskell.record.definition.property.field.property.name" />
626519 </scope>
627520 </collection>
628521
629522 <collection name="type">
523+ <scope name="haskell.keyword.construct.function-arrow">
524+ <expression>-></expression>
525+ </scope>
526+ <scope name="haskell.keyword.construct.fat-arrow">
527+ <expression>=></expression>
528+ </scope>
529+ <include syntax="self" collection="strings" />
630530 <scope name="haskell.type.construct.tuple">
631531 <starts-with>
632532 <expression>\(</expression>
@@ -635,6 +535,7 @@
635535 <expression>\)</expression>
636536 </ends-with>
637537 <subscopes>
538+ <include syntax="self" collection="comments" />
638539 <scope name="haskell.construct.type.typle.comma">
639540 <expression>\,</expression>
640541 </scope>
@@ -649,6 +550,7 @@
649550 <expression>\]</expression>
650551 </ends-with>
651552 <subscopes>
553+ <include syntax="self" collection="comments" />
652554 <include syntax="self" collection="type" />
653555 </subscopes>
654556 </scope>
@@ -660,7 +562,7 @@
660562 </scope>
661563 <include syntax="self" collection="type-list" />
662564 <scope>
663− <expression>(([A-Z](\w|')*\.)*)'*([A-Z](\w|')*)</expression>
565+ <expression>(([A-Z](\w|')*\.)*)'*\!?([A-Z](\w|')*)</expression>
664566 <capture number="1" name="haskell.identifier.package.module" />
665567 <capture number="4" name="haskell.identifier.type" />
666568 </scope>
@@ -668,13 +570,7 @@
668570 <expression>forall</expression>
669571 </scope>
670572 <scope name="haskell.identifier.type.variable">
671− <expression>(?!=)((?!(\(|\)|\,))\S)((?!(\(|\)|\,))\S)*</expression>
672− </scope>
673− <scope name="haskell.keyword.construct.function-arrow">
674− <expression>-></expression>
675− </scope>
676− <scope name="haskell.keyword.construct.fat-arrow">
677− <expression>=></expression>
573+ <expression>(?!where)(?!=)((?!(\(|\)|\,|\!))\S)((?!(\(|\)|\,))\w)*</expression>
678574 </scope>
679575 </collection>
680576
@@ -689,6 +585,7 @@
689585 <template>^(?!\s+\1\S)(?!\s*$)</template>
690586 </ends-with>
691587 <subscopes>
588+ <include syntax="self" collection="comments" />
692589 <scope name="haskell.keyword.construct.where">
693590 <expression>where</expression>
694591 </scope>
@@ -708,6 +605,7 @@
708605 <capture number="1" name="haskell.type-list.bracket" />
709606 </ends-with>
710607 <subscopes>
608+ <include syntax="self" collection="comments" />
711609 <include syntax="self" collection="type" />
712610 </subscopes>
713611 </scope>
@@ -724,6 +622,7 @@
724622 <capture number="1" name="haskell.keyword.construct.lambda" />
725623 </ends-with>
726624 <subscopes>
625+ <include syntax="self" collection="comments" />
727626 <include syntax="self" collection="pattern-match" />
728627 </subscopes>
729628 </scope>
@@ -737,7 +636,6 @@
737636
738637 <collection name="where-clause">
739638 <scope name="haskell.construct.where">
740− <local scope="within-parent" />
741639 <starts-with>
742640 <expression>^(\h*)(where)</expression>
743641 <capture number="2" name="haskell.construct.keyword.where" />
@@ -746,6 +644,7 @@
746644 <template>^(?!\1\s*\S)(?!s*$)</template>
747645 </ends-with>
748646 <subscopes>
647+ <include syntax="self" collection="comments" />
749648 <include syntax="self" collection="definition" />
750649 </subscopes>
751650 </scope>
@@ -785,12 +684,12 @@
785684
786685
787686 <collection name="strings">
788− <scope name="haskell.string.double-quoted">
687+ <scope name="haskell.string.double-quoted" spell-check="true">
789688 <starts-with>
790− <expression>"</expression>
689+ <expression>"</expression>
791690 </starts-with>
792691 <ends-with>
793− <expression>"</expression>
692+ <expression>"</expression>
794693 </ends-with>
795694 <subscopes>
796695 <scope name="haskell.string.escape-sequences">
@@ -827,6 +726,7 @@
827726 </ends-with>
828727 <subscopes>
829728 <scope name="identifier.haskell.type">
729+ <symbol type="expression" />
830730 <symbol type="expression" />
831731 <expression>([A-Z](\w|')*)\h*(\(\h*\.\.\h*\))?</expression>
832732 <capture number="1" name="identifier.type" />
@@ -851,6 +751,7 @@
851751 </ends-with>
852752 <subscopes>
853753 <scope name="haskell.construct.qualified">
754+ <symbol type="expression" />
854755 <expression>qualified</expression>
855756 <capture number="0" name="haskell.construct.keyword.qualified" />
856757 </scope>
@@ -868,6 +769,7 @@
868769 </ends-with>
869770 <subscopes anchored="true">
870771 <include syntax="self" collection="import-list" />
772+ <symbol type="expression" />
871773 </subscopes>
872774 </scope>
873775
@@ -901,6 +803,7 @@
901803 </ends-with>
902804 <subscopes>
903805 <scope name="haskell.identifier.struct">
806+ <symbol type="expression" />
904807 <symbol type="reference" scope="local" />
905808 <expression>([A-Z](\w|')*)\h*(\(\h*\.\.\h*\))?</expression>
906809 <capture number="1" name="haskell.import-list.identifier.type.name" />
@@ -914,13 +817,6 @@
914817 </scope>
915818 </collection>
916819
917− <!-- <collection name="special">
918− <scope>
919− <expression>(;|,)</expression>
920− </scope>
921− </collection> -->
922−
923−
924820 <collection name="reservedop">
925821 <scope name="keyword.operator">
926822 <expression>(\.\.|:|::|=|\\|\||<-|->|@|~|=>)</expression>
@@ -928,10 +824,11 @@
928824 </collection>
929825
930826 <collection name="keywords">
931− <scope name="haskell.keyword.modifier">
827+ <scope name="haskell.keyword.self">
932828 <symbol type="keyword" />
933829 <strings>
934830 <string>do</string>
831+ <string>mdo</string>
935832 <string>in</string>
936833 <string>infix</string>
937834 <string>infixl</string>
@@ -969,20 +866,18 @@
969866 <strings>
970867 <string>undefined</string>
971868 <string>_</string>
869+ <string>@</string>
972870 </strings>
973871 </scope>
974872 </collection>
975873
976874 <collection name="comments">
977875 <scope name="haskell.comment.single" spell-check="true">
978− <starts-with>
979− <expression>--</expression>
980− </starts-with>
981− <ends-with>
982− <expression>$</expression>
983− </ends-with>
876+ <symbol type="comment" />
877+ <expression> --.*$</expression>
984878 </scope>
985879 <scope name="haskell.comment.block" spell-check="true">
880+ <symbol type="comment" />
986881 <starts-with>
987882 <expression>{-</expression>
988883 </starts-with>
@@ -994,4 +889,4 @@
994889
995890
996891 </collections>
997−</syntax>
892+</syntax>