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

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

[nongnu] elpa/geiser 67fae675d4 2/2: geiser-debug: ensure next-error buf


From: ELPA Syncer
Subject: [nongnu] elpa/geiser 67fae675d4 2/2: geiser-debug: ensure next-error buffer and buttonize output
Date: Sun, 23 Oct 2022 19:58:33 -0400 (EDT)

branch: elpa/geiser
commit 67fae675d40833fe10471a6b237a16efef03b845
Author: jao <jao@gnu.org>
Commit: jao <jao@gnu.org>

    geiser-debug: ensure next-error buffer and buttonize output
---
 elisp/geiser-debug.el | 12 +++++++++---
 1 file changed, 9 insertions(+), 3 deletions(-)

diff --git a/elisp/geiser-debug.el b/elisp/geiser-debug.el
index a0c2c51caa..01a6ab628e 100644
--- a/elisp/geiser-debug.el
+++ b/elisp/geiser-debug.el
@@ -192,6 +192,11 @@ buffer.")
         (newline 2)
         (and no (> no 0))))))
 
+(defun geiser-debug--default-display-error (key msg)
+  (insert "\n"
+          (if key (format "Error: %s\n" key) "")
+          (format "%s" (or msg "")) "\n"))
+
 (defun geiser-debug--display-retort (what ret &optional res _auto-p)
   (let* ((err (geiser-eval--retort-error ret))
          (key (geiser-eval--error-key err))
@@ -220,11 +225,12 @@ buffer.")
         (setq img (when (and res (not err) (not debug))
                     (geiser-debug--insert-res res)))
         (when (or err key output)
+          (when (fboundp 'next-error-select-buffer)
+            (next-error-select-buffer (current-buffer)))
           (let ((msg (or (geiser-eval--error-msg err) output "")))
             (or (geiser-debug--display-error impl module key msg)
-                (insert "\n"
-                        (if key (format "Error: %s\n" key) "")
-                        (format "%s" (or msg "")) "\n"))))
+                (geiser-debug--default-display-error key msg))
+            (unless err (geiser-edit--buttonize-files))))
         (when after
           (goto-char (point-max))
           (insert "\nExpression evaluated was:\n\n")



reply via email to

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