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

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

[nongnu] elpa/htmlize 315a8f2 121/134: htmlize-sorted-overlays-at: corre


From: ELPA Syncer
Subject: [nongnu] elpa/htmlize 315a8f2 121/134: htmlize-sorted-overlays-at: correctly initialize OVERLAYS. (#18)
Date: Sat, 7 Aug 2021 09:17:20 -0400 (EDT)

branch: elpa/htmlize
commit 315a8f23cfd3e87642ff9e30ae3300c7a84244d5
Author: Hrvoje Niksic <hniksic@gmail.com>
Commit: Hrvoje Niksic <hniksic@gmail.com>

    htmlize-sorted-overlays-at: correctly initialize OVERLAYS. (#18)
---
 htmlize.el | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/htmlize.el b/htmlize.el
index 6cbe110..3584b83 100644
--- a/htmlize.el
+++ b/htmlize.el
@@ -1281,9 +1281,10 @@ overlays that specify `face'."
 
   (defun htmlize-sorted-overlays-at (pos)
     ;; Like OVERLAYS-AT with the SORTED argument, for older Emacsen.
-    (let ((overlays (sort* overlays #'<
-                           :key (lambda (o)
-                                  (- (overlay-end o) (overlay-start o))))))
+    (let ((overlays (overlays-at pos)))
+      (setq overlays (sort* overlays #'<
+                            :key (lambda (o)
+                                   (- (overlay-end o) (overlay-start o)))))
       (setq overlays
             (stable-sort overlays #'<
                          :key (lambda (o)



reply via email to

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