[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Instead of pcase
From: |
Richard Stallman |
Subject: |
Re: Instead of pcase |
Date: |
Sun, 10 Dec 2023 10:14:09 -0500 |
[[[ To any NSA and FBI agents reading my email: please consider ]]]
[[[ whether defending the US Constitution against all enemies, ]]]
[[[ foreign or domestic, requires you to follow Snowden's example. ]]]
I am trying to rewrite `byte-optimize-letX' with cond*,
but I cannot understand its current definition.
Specifically, I can't understand this pcase clause:
;; Body is last variable.
(`(,head ,(and bindings
(let last-var (caar (last bindings))))
,(and last-var ; non-linear pattern
(pred symbolp) (pred (not keywordp)) (pred (not booleanp))))
(if (eq head 'let)
`(progn ,@(mapcar #'cadr bindings))
`(,head ,(butlast bindings) ,(cadar (last bindings)))))
What case is it meant to handle? What does that case look like?
The comments cited in that code make no sense to me; I don't know of
any use of `let' or `let*' in which the body would be one of the
variables, and their doc strings don't describe any new usage which
would make that meaningful.
--
Dr Richard Stallman (https://stallman.org)
Chief GNUisance of the GNU Project (https://gnu.org)
Founder, Free Software Foundation (https://fsf.org)
Internet Hall-of-Famer (https://internethalloffame.org)
- Re: Instead of pcase, (continued)
Re: Instead of pcase, Michael Heerdegen, 2023/12/02
Re: Instead of pcase, Lynn Winebarger, 2023/12/02
Re: Instead of pcase, Richard Stallman, 2023/12/02
Re: Instead of pcase, Richard Stallman, 2023/12/01
Re: Instead of pcase, Lynn Winebarger, 2023/12/02
Re: Instead of pcase,
Richard Stallman <=
- Re: Instead of pcase, Lynn Winebarger, 2023/12/10
- Re: Instead of pcase, Michael Heerdegen, 2023/12/10
- Re: Instead of pcase, Lynn Winebarger, 2023/12/10
- Re: Instead of pcase, Richard Stallman, 2023/12/11
- Re: Instead of pcase, Tomas Hlavaty, 2023/12/12
- RE: [External] : Re: Instead of pcase, Drew Adams, 2023/12/12
- Re: [External] : Re: Instead of pcase, Richard Stallman, 2023/12/13
- RE: [External] : Re: Instead of pcase, Drew Adams, 2023/12/14
- Re: [External] : Re: Instead of pcase, Richard Stallman, 2023/12/15
- RE: [External] : Re: Instead of pcase, Drew Adams, 2023/12/16