bug-gnu-emacs
[Top][All Lists]
Advanced

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

bug#26540: 25.2; [PATCH] Add cl-set-equal to test for set equality


From: Damien Cassou
Subject: bug#26540: 25.2; [PATCH] Add cl-set-equal to test for set equality
Date: Tue, 18 Apr 2017 13:21:41 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/25.2 (gnu/linux)

Drew Adams <address@hidden> writes:

This patch adds cl-seq-equal to test whether two lists have the same elements. I.e., if every element of LIST1 also appears in LIST2 and if every element of LIST2 also appears in LIST1.

Common Lisp (and the Emacs emulation) already has set functions that do this - `[cl-]set-exclusive-or', for example. https://www.cs.cmu.edu/Groups/AI/html/cltl/clm/node152.html

are you saying that (1) I should propose an implementation of set-equal based on set-exclusive-or (I guess it's just a `not` call away) or (2) not propose set-equal all together? I understand (1), but not the reasoning behind (2).
--
Damien Cassou
http://damiencassou.seasidehosting.st

"Success is the ability to go from one failure to another without
losing enthusiasm." --Winston Churchill





reply via email to

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