[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Replace trivial pcase occurrences in the Emacs sources
From: |
Eli Zaretskii |
Subject: |
Re: Replace trivial pcase occurrences in the Emacs sources |
Date: |
Wed, 24 Oct 2018 19:00:25 +0300 |
> From: Clément Pit-Claudel <address@hidden>
> Date: Wed, 24 Oct 2018 11:47:03 -0400
>
> On 24/10/2018 11.03, Eli Zaretskii wrote:
> > Is it because people are too lazy to write (eq a b) as part of 'cond'?
> > Or is there something else I'm missing?
> I think some of us (me, at least), just like the forms you posted better :)
Which forms? with or without the mistakes? ;-)
> The repetition of "eq" in each "cond" branch just looks redundant to me
If that's what bugs you, then how about
(setq foo (assoc bar '((1 . one) (2 . two) ...)))
?
> and I have no trouble reading the pcase forms.
Please don't forget those who will read your code. A code is written
once, but read many times. It should be readable and
self-explanatory.
- Re: Replace trivial pcase occurrences in the Emacs sources, (continued)
- Re: Replace trivial pcase occurrences in the Emacs sources, Eli Zaretskii, 2018/10/30
- Re: Replace trivial pcase occurrences in the Emacs sources, Michael Heerdegen, 2018/10/30
- Re: Replace trivial pcase occurrences in the Emacs sources, Eli Zaretskii, 2018/10/30
- Re: Replace trivial pcase occurrences in the Emacs sources, Michael Heerdegen, 2018/10/30
- Re: Replace trivial pcase occurrences in the Emacs sources, Eli Zaretskii, 2018/10/31
- Re: Replace trivial pcase occurrences in the Emacs sources, Stefan Monnier, 2018/10/31
- Re: Replace trivial pcase occurrences in the Emacs sources, Clément Pit-Claudel, 2018/10/24
- Re: Replace trivial pcase occurrences in the Emacs sources,
Eli Zaretskii <=
- Re: Replace trivial pcase occurrences in the Emacs sources, Clément Pit-Claudel, 2018/10/24
- Re: Replace trivial pcase occurrences in the Emacs sources, Eli Zaretskii, 2018/10/24
- Re: Replace trivial pcase occurrences in the Emacs sources, Alan Mackenzie, 2018/10/24
- Re: Replace trivial pcase occurrences in the Emacs sources, Stefan Monnier, 2018/10/24
- Re: Replace trivial pcase occurrences in the Emacs sources, Stephen Berman, 2018/10/25
- Re: Replace trivial pcase occurrences in the Emacs sources, Eli Zaretskii, 2018/10/25
- Re: Replace trivial pcase occurrences in the Emacs sources, Stefan Monnier, 2018/10/25
- Re: Replace trivial pcase occurrences in the Emacs sources, Stefan Monnier, 2018/10/26
- Re: Replace trivial pcase occurrences in the Emacs sources, Garreau\, Alexandre, 2018/10/27
- Re: Replace trivial pcase occurrences in the Emacs sources, Richard Stallman, 2018/10/24