[Top][All Lists]

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

Re: 7 logical-xor implementations in source tree

From: Basil L. Contovounesios
Subject: Re: 7 logical-xor implementations in source tree
Date: Thu, 01 Aug 2019 01:05:40 +0300
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux)

Drew Adams <address@hidden> writes:

> I don't understand what all the excitement
> about defining an `xor' (with whatever name)
> operator is about.
> Common Lisp, like Emacs Lisp, has a bit-wise
> xor operator.  That makes sense - useful.
> And Common Lisp, like Emacs Lisp, does _not_
> have an xor operator for arbitrary Lisp values.
> https://www.cs.cmu.edu/Groups/AI/html/cltl/clm/node75.html
> Why is it important that Emacs Lisp have such
> an operator?  (Answer: it's not - YAGNI.)

If YAGNI, why are there currently 7 copies of this function in the Emacs

No-one said it's vitally important; it's just a minor nice-to-have.

> Is it hard to understand (eq (not a) (not b))?
> Is evaluation of that inefficient?  Is it too
> verbose?
> What's the motivation for all of this?

Same reason proper-list-p was added: reducing existing code duplication
and providing yet another convenience function for those that like it.

> My vote's against adding any such operator.


reply via email to

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