[Top][All Lists]

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

Re: if-let/if-let*/and-let/..

From: Stefan Monnier
Subject: Re: if-let/if-let*/and-let/..
Date: Tue, 13 Feb 2018 14:24:08 -0500
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux)

> I think it is worth it, for the same reason we keep having `when' though
> we have `if' or `and': to make code better readable and its intention
> better understandable.

I was OK with having if-let and when-let, yes.

I think more than 2 alternative semantics is hard to justify, tho:
I don't even see a single use of and-let (other than in tests).

>> > Another question is why aren't when-let and when-let* aliases of
>> > each other?  Currently we have 5 variants (2 of which are
>> > deprecated) each with very slightly different semantics.
> That makes no sense, indeed.  Would keeping both names as aliases be ok
> to you?


> So, what are your suggestions?

I think we should drop `and-let` and make if/when-let aliases of if/when-let*
(or the reverse).  I think it could still be done on emacs-26.


reply via email to

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