emacs-devel
[Top][All Lists]
Advanced

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

Re: pcase: Semantics of atom QPATS


From: Michael Heerdegen
Subject: Re: pcase: Semantics of atom QPATS
Date: Wed, 13 Jun 2018 05:41:32 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux)

Stefan Monnier <address@hidden> writes:

> Which is why I prefer signaling an error: it lets us extend the
> semantics of ` without any fear of breaking backward compatibility.

May I add a comment like this to clarify?

 lisp/emacs-lisp/pcase.el | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/lisp/emacs-lisp/pcase.el b/lisp/emacs-lisp/pcase.el
index d3e8899706..32c36ab2cd 100644
--- a/lisp/emacs-lisp/pcase.el
+++ b/lisp/emacs-lisp/pcase.el
@@ -981,6 +981,8 @@ pcase--u1
           (app car ,(list '\` (car qpat)))
           (app cdr ,(list '\` (cdr qpat)))))
    ((or (stringp qpat) (integerp qpat) (symbolp qpat)) `',qpat)
+   ;; In all other cases just raise an error so we can't break
+   ;; backward compatibility in the future:
    (t (error "Unknown QPAT: %S" qpat))))
 
 (provide 'pcase)
-- 


Michael.



reply via email to

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