[Top][All Lists]

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

Re: The poor state of documentation of pcase like things.

From: Michael Heerdegen
Subject: Re: The poor state of documentation of pcase like things.
Date: Fri, 25 Dec 2015 15:59:37 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/25.0.50 (gnu/linux)

Richard Stallman <address@hidden> writes:

> That comma won't add much to the size of the code, and typing it is
> not much work.  But I think that avoiding it would make pcase more
> attractive and conceptually simpler.

But it will make it conceptually more complicated, because we would
obfuscate the real semantics.  A tool with inconsistent semantics is
neither simple nor attractive.

If you understand "_" as a "concept" per se in Elisp, I think we agree
that in your case it doesn't fit the expectations of how you think it
would integrate in pcase's semantics.  If we make it just look like some
people guess it would be working, we are not doing them a favor, because
we just spare them to learn the real semantics at the moment.  That will
make it harder to learn pcase, not easier.  If for some people the thing
is different as they first expect, avoiding to let them see that it is
different is not good, just for the sake of making it look more familiar
at the first look.  I think people will then more likely forget commas
at other places in ` patterns.  They will have more problems to
understand more complicated ` patterns.  It is important to understand
that _ is a pattern in pcase, a pattern like any other pcase pattern,
and not something else or special.

OTOH after you have written ",_" for yourself a three times or so,
you'll just have gotten used to it.



reply via email to

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