emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[nongnu] elpa/annotate ed6a7dd7cc 180/372: - prevented fails of fontific


From: ELPA Syncer
Subject: [nongnu] elpa/annotate ed6a7dd7cc 180/372: - prevented fails of fontification of annotated regions
Date: Fri, 4 Feb 2022 16:58:57 -0500 (EST)

branch: elpa/annotate
commit ed6a7dd7ccd6c784b4d44438c1314b3b5f81dbb9
Author: cage <cage-invalid@invalid>
Commit: cage <cage-invalid@invalid>

    - prevented fails of fontification of annotated regions
      As we walk across the overlays we can get past the limit, the best i
      figured  out to  fix  that was  to check  point  even before  regexp
      matching.
---
 annotate.el | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/annotate.el b/annotate.el
index 884424ed06..721a4e7d55 100644
--- a/annotate.el
+++ b/annotate.el
@@ -648,7 +648,8 @@ annotation plus the newline."
       ;; capture the area from the overlay to EOL (regexp match #1)
       ;; for the modification guard and the newline itself (regexp
       ;; match #2) for the annotation.
-      (re-search-forward "\\(.*\\(\n\\)\\)" limit t))))
+      (when (< (point) limit)
+        (re-search-forward "\\(.*\\(\n\\)\\)" limit t)))))
 
 (cl-defstruct annotate-group
   words



reply via email to

[Prev in Thread] Current Thread [Next in Thread]