all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* pcase with progn
@ 2024-11-27 18:45 Heime via Users list for the GNU Emacs text editor
  2024-11-27 19:39 ` Scott Bell
  2024-11-28 14:44 ` Stefan Monnier via Users list for the GNU Emacs text editor
  0 siblings, 2 replies; 5+ messages in thread
From: Heime via Users list for the GNU Emacs text editor @ 2024-11-27 18:45 UTC (permalink / raw)
  To: Heime via Users list for the GNU Emacs text editor


Does pcase require progn for multiple commands?

(defun pola-symbol-name (sbl &optional sel)
  "Get the string representation of symbol SBL.  If it is
already a string, return it unchanged."

  (cond
    ((symbolp sbl) (symbol-name sbl))
    ((stringp sbl) sbl)
    (t (pcase sel
         ('nil (error "SBL must be a symbol or a string: %s" sbl))
         ('nil-output nil)
         ('default "unknown")
         ('warn (progn
                  (message "SBL not symbol nor string: %s" sbl)
                  nil))
         ('pass sbl)
         (_ (error "SEL Invalid: %s" sel))))))



Sent with Proton Mail secure email.



^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2024-11-28 14:44 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-11-27 18:45 pcase with progn Heime via Users list for the GNU Emacs text editor
2024-11-27 19:39 ` Scott Bell
2024-11-27 20:50   ` Heime via Users list for the GNU Emacs text editor
2024-11-27 22:33     ` Scott Bell
2024-11-28 14:44 ` Stefan Monnier via Users list for the GNU Emacs text editor

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.