emacs-diffs
[Top][All Lists]
Advanced

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

emacs-29 4a7e657389a: * lisp/emacs-lisp/comp.el (comp-prettyformat-insn)


From: Andrea Corallo
Subject: emacs-29 4a7e657389a: * lisp/emacs-lisp/comp.el (comp-prettyformat-insn): Fix (bug#61917)
Date: Mon, 6 Mar 2023 11:24:05 -0500 (EST)

branch: emacs-29
commit 4a7e657389a2c6367911b381bdf86dd83c09d325
Author: Andrea Corallo <akrl@sdf.org>
Commit: Andrea Corallo <akrl@sdf.org>

    * lisp/emacs-lisp/comp.el (comp-prettyformat-insn): Fix (bug#61917)
---
 lisp/emacs-lisp/comp.el | 10 ++++++----
 1 file changed, 6 insertions(+), 4 deletions(-)

diff --git a/lisp/emacs-lisp/comp.el b/lisp/emacs-lisp/comp.el
index 72e9b8e37dc..a1838b1abf2 100644
--- a/lisp/emacs-lisp/comp.el
+++ b/lisp/emacs-lisp/comp.el
@@ -1137,10 +1137,12 @@ with `message'.  Otherwise, log with 
`comp-log-to-buffer'."
           (comp-cstr-to-type-spec mvar)))
 
 (defun comp-prettyformat-insn (insn)
-  (cl-typecase insn
-    (comp-mvar (comp-prettyformat-mvar insn))
-    (atom (prin1-to-string insn))
-    (cons (concat "(" (mapconcat #'comp-prettyformat-insn insn " ") ")"))))
+  (cond
+   ((comp-mvar-p insn)
+    (comp-prettyformat-mvar insn))
+   ((proper-list-p insn)
+    (concat "(" (mapconcat #'comp-prettyformat-insn insn " ") ")"))
+   (t (prin1-to-string insn))))
 
 (defun comp-log-func (func verbosity)
   "Log function FUNC at VERBOSITY.



reply via email to

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