File tree Expand file tree Collapse file tree 3 files changed +12
-5
lines changed Expand file tree Collapse file tree 3 files changed +12
-5
lines changed Original file line number Diff line number Diff line change @@ -586,10 +586,10 @@ on an uppercase identifier."
586
586
(goto-char (1+ (point )))))))
587
587
; ; must return nil here so that it is not fontified again as string
588
588
nil ))
589
- ; ; Detect literate comment lines starting with syntax class '< '
589
+ ; ; Detect literate comment lines starting with syntax class '! '
590
590
((save-excursion
591
591
(goto-char (nth 8 state))
592
- (equal (string-to-syntax " < " ) (syntax-after (point ))))
592
+ (equal (string-to-syntax " ! " ) (syntax-after (point ))))
593
593
'haskell-literate-comment-face )
594
594
; ; Detect pragmas. A pragma is enclosed in special comment
595
595
; ; delimiters {-# .. #-}.
Original file line number Diff line number Diff line change @@ -475,7 +475,7 @@ See `haskell-lexeme-classify-by-first-char' for details."
475
475
(point (point-marker )))
476
476
(or
477
477
(and
478
- (equal (string-to-syntax " < " )
478
+ (equal (string-to-syntax " ! " )
479
479
(get-char-property (point ) 'syntax-table ))
480
480
(progn
481
481
(set-match-data (list point (set-marker (make-marker ) (line-end-position ))))
Original file line number Diff line number Diff line change @@ -505,14 +505,18 @@ be set to the preferred literate style."
505
505
(or
506
506
(and
507
507
(not (equal (string-to-syntax " <" ) (syntax-after (point ))))
508
+ (not (equal (string-to-syntax " !" ) (syntax-after (point ))))
508
509
(not (looking-at-p " ^>" )))
509
510
(looking-at-p " ^\\\\ begin{code}[\t ]*$" )))))))
510
511
(while (< (point ) end)
511
512
(unless (looking-at-p " ^[\t ]*$" )
512
513
(if previous-line-latex-code
513
514
(if (looking-at-p " ^\\\\ end{code}[\t ]*$" )
514
515
(progn
515
- (put-text-property (point ) (1+ (point )) 'syntax-table (string-to-syntax " <" ))
516
+ (put-text-property (point ) (1+ (point )) 'syntax-table (string-to-syntax " !" ))
517
+ (save-excursion
518
+ (end-of-line )
519
+ (put-text-property (point ) (1+ (point )) 'syntax-table (string-to-syntax " !" )))
516
520
(setq previous-line-latex-code nil ))
517
521
; ; continue latex-code
518
522
)
@@ -521,7 +525,10 @@ be set to the preferred literate style."
521
525
(put-text-property (point ) (1+ (point )) 'syntax-table (string-to-syntax " -" ))
522
526
; ; this is a literate comment
523
527
(progn
524
- (put-text-property (point ) (1+ (point )) 'syntax-table (string-to-syntax " <" ))
528
+ (put-text-property (point ) (1+ (point )) 'syntax-table (string-to-syntax " !" ))
529
+ (save-excursion
530
+ (end-of-line )
531
+ (put-text-property (point ) (1+ (point )) 'syntax-table (string-to-syntax " !" )))
525
532
(when (looking-at-p " ^\\\\ begin{code}[\t ]*$" )
526
533
(setq previous-line-latex-code t ))))))
527
534
(forward-line 1 ))))
You can’t perform that action at this time.
0 commit comments