@@ -1402,7 +1402,8 @@ repository:
1402
1402
patterns :
1403
1403
# Fully reserved symbols,
1404
1404
# not including '::' (special treatment as it starts type highlighting),
1405
- # nor '=>' (it highlights its precedent as a type).
1405
+ # nor '=>' (it highlights its precedent as a type),
1406
+ # nor '∀' (highlights subsequent dot for quantification).
1406
1407
- match : >-
1407
1408
(?x)
1408
1409
(?<![\p{S}\p{P}&&[^(),;\[\]`{}_"'']])
@@ -1418,7 +1419,6 @@ repository:
1418
1419
|(-<<|⤛)
1419
1420
|(>-|⤚)
1420
1421
|(>>-|⤜)
1421
- |(∀)
1422
1422
)
1423
1423
(?![\p{S}\p{P}&&[^(),;\[\]`{}_"'']])
1424
1424
captures:
@@ -1433,7 +1433,6 @@ repository:
1433
1433
'9': {name: keyword.operator.arrow.left.tail.double.haskell}
1434
1434
'10': {name: keyword.operator.arrow.tail.haskell}
1435
1435
'11': {name: keyword.operator.arrow.tail.double.haskell}
1436
- '12': {name: keyword.other.forall.haskell}
1437
1436
# Reserved postfix symbol: '#'
1438
1437
# This allows users to specify highlighting of '#' dependent on theme,
1439
1438
# as we are unfortunately unable to make a decision based on enabled extensions.
@@ -1501,10 +1500,27 @@ repository:
1501
1500
'4': {name: storage.type.infix.haskell}
1502
1501
'5': {name: punctuation.backtick.haskell}
1503
1502
forall :
1504
- begin : ' \b(?<!'' )(forall|∀)\b(?!'' )'
1503
+ begin : >-
1504
+ (?x)
1505
+ # Alphabetic forall
1506
+ (?:
1507
+ \b(?<!')
1508
+ (forall)
1509
+ \b(?!')
1510
+ )
1511
+ |
1512
+ # Symbolic forall
1513
+ (?:
1514
+ # Not preceded by a symbol except reserved symbols
1515
+ (?<![\p{S}\p{P}&&[^(),;\[\]`{}_"'']])
1516
+ (∀)
1517
+ # Not followed by a symbol except reserved symbols
1518
+ (?![\p{S}\p{P}&&[^(),;\[\]`{}_"'']])
1519
+ )
1505
1520
end : ' (\.)|(->|→)'
1506
1521
beginCaptures :
1507
1522
' 1 ' : {name: keyword.other.forall.haskell}
1523
+ ' 2 ' : {name: keyword.other.forall.haskell}
1508
1524
endCaptures :
1509
1525
' 1 ' : {name: keyword.operator.period.haskell}
1510
1526
' 2 ' : {name: keyword.operator.arrow.haskell}
0 commit comments