[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#51368: 29.0.50; `cl-case' should error on incorrect use
From: |
Andreas Schwab |
Subject: |
bug#51368: 29.0.50; `cl-case' should error on incorrect use |
Date: |
Sun, 24 Oct 2021 10:16:07 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/27.2 (gnu/linux) |
On Okt 24 2021, Philipp Stephani wrote:
> This form demonstrates a few incorrect uses of `cl-case':
>
> (cl-case a
> (nil 0) ; doesn't match anything
> (t 1) ; matches everything, but too early
> ('foo 2)) ; matches `quote' in addition to `foo'
>
> It would be nice if `cl-case' would signal an error or at least warn
> about these at macroexpansion time, since they are somewhat subtle and
> easy to get wrong.
clisp errors out on the misplaced `t' clause, but is otherwise silent.
Andreas.
--
Andreas Schwab, schwab@linux-m68k.org
GPG Key fingerprint = 7578 EB47 D4E5 4D69 2510 2552 DF73 E780 A9DA AEC1
"And now for something completely different."