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

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

bug#47368: 28.0.50; map-elt returns nil without "deprecated" TESTFN


From: Basil L. Contovounesios
Subject: bug#47368: 28.0.50; map-elt returns nil without "deprecated" TESTFN
Date: Fri, 26 Mar 2021 18:57:13 +0000
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux)

Stefan Monnier <monnier@iro.umontreal.ca> writes:

>> What's a good way to solve this?  Obviously the map abstraction doesn't
>> fit so super well for alists because unlike the other map type alists
>> don't know "their" test function.  But disallowing alists that don't
>> test with `eq' seems an unnecessary restriction.  Can we say that the
>> argument is allowed only for alists?
>
> How 'bout always using `equal`?

No objections here.  CCing Nicolas in case he has any comments.

Just some code archaeology for more context:

- Pre-Emacs-25 map-elt used assoc.
- Emacs 25 map-elt used alist-get without TESTFN.
- Emacs 26 map-elt gained TESTFN at the same time that alist-get did,
  in https://bugs.gnu.org/27584.
- Emacs 27 deprecated map-elt's TESTFN.

-- 
Basil





reply via email to

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