@@ -155,7 +155,13 @@ font faces assigned as if respective mode was enabled."
155155;;;### autoload
156156(defface haskell-pragma-face
157157 '((t :inherit font-lock-preprocessor-face ))
158- " Face used to highlight Haskell pragmas."
158+ " Face used to highlight Haskell pragmas ({-# ... #-})."
159+ :group 'haskell-appearance )
160+
161+ ;;;### autoload
162+ (defface haskell-liquid-haskell-annotation-face
163+ '((t :inherit haskell-pragma-face))
164+ " Face used to highlight LiquidHaskell annotations ({-@ ... @-})."
159165 :group 'haskell-appearance )
160166
161167;;;### autoload
@@ -512,14 +518,23 @@ like ::, class, instance, data, newtype, type."
512518 (equal (string-to-syntax " <" ) (syntax-after (point ))))
513519 'haskell-literate-comment-face )
514520 ; ; Detect pragmas. A pragma is enclosed in special comment
515- ; ; delimeters {-# .. #-}.
521+ ; ; delimiters {-# .. #-}.
516522 ((save-excursion
517523 (goto-char (nth 8 state))
518524 (and (looking-at-p " {-#" )
519525 (forward-comment 1 )
520526 (goto-char (- (point ) 3 ))
521527 (looking-at-p " #-}" )))
522528 'haskell-pragma-face )
529+ ; ; Detect Liquid Haskell annotations enclosed in special comment
530+ ; ; delimiters {-@ .. @-}.
531+ ((save-excursion
532+ (goto-char (nth 8 state))
533+ (and (looking-at-p " {-@" )
534+ (forward-comment 1 )
535+ (goto-char (- (point ) 3 ))
536+ (looking-at-p " @-}" )))
537+ 'haskell-liquid-haskell-annotation-face )
523538 ; ; Haddock comment start with either "-- [|^*$]" or "{- ?[|^*$]"
524539 ; ; (note space optional for nested comments and mandatory for
525540 ; ; double dash comments).
0 commit comments