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

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

[nongnu] elpa/sesman a428dc955c 050/100: Improve readable of sesman-grou


From: ELPA Syncer
Subject: [nongnu] elpa/sesman a428dc955c 050/100: Improve readable of sesman-grouped-links
Date: Tue, 28 Dec 2021 14:06:01 -0500 (EST)

branch: elpa/sesman
commit a428dc955cd257cc9ac50d286c551c6809c2160b
Author: Vitalie Spinu <spinuvit@gmail.com>
Commit: Vitalie Spinu <spinuvit@gmail.com>

    Improve readable of sesman-grouped-links
---
 sesman.el | 17 +++++++++--------
 1 file changed, 9 insertions(+), 8 deletions(-)

diff --git a/sesman.el b/sesman.el
index fe777dca0d..a2438afe83 100644
--- a/sesman.el
+++ b/sesman.el
@@ -635,18 +635,19 @@ If AS-STRING is non-nil, return an equivalent string 
representation."
                               (assoc type out-rel)
                             (assoc type out))))
               (when entry
-                (setcdr entry (cons val (cdr entry))))))
+                (setcdr entry (cons link (cdr entry))))))
           links)
     (let ((out (delq nil (mapcar (lambda (el) (and (cdr el) el)) out)))
           (out-rel (delq nil (mapcar (lambda (el) (and (cdr el) el)) 
out-rel))))
       (if as-string
-          (let ((fmt-fn (lambda (link-vals)
-                          (let ((type (car link-vals)))
-                            (mapconcat (lambda (v)
-                                         (format "%s(%s)"
-                                                 (or (plist-get 
sesman--cxt-abbrevs type) type)
-                                                 (sesman--abbrev-path-maybe 
v)))
-                                       (cdr link-vals)
+          (let ((fmt-fn (lambda (typed-links)
+                          (let* ((type (car typed-links))
+                                 (short-type (or (plist-get 
sesman--cxt-abbrevs type) type)))
+                            (mapconcat (lambda (lnk)
+                                         (format "%s(%s)" short-type
+                                                 (sesman--abbrev-path-maybe
+                                                  (sesman--lnk-value lnk))))
+                                       (cdr typed-links)
                                        ", ")))))
             (if out-rel
                 (concat (mapconcat fmt-fn out-rel ", ")



reply via email to

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