1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2025-12-16 02:50:26 -08:00

Revert "alist-get testfn argument evaluation correction"

This reverts commit 17d65c99cd.

Please don't install unnecessary improvements on the release
branch.
This commit is contained in:
Eli Zaretskii 2022-12-16 19:29:30 +02:00
parent 856d889f3a
commit de2239a584

View file

@ -417,9 +417,9 @@ The return value is the last VAL in the list.
(lambda (do key alist &optional default remove testfn) (lambda (do key alist &optional default remove testfn)
(macroexp-let2 macroexp-copyable-p k key (macroexp-let2 macroexp-copyable-p k key
(gv-letplace (getter setter) alist (gv-letplace (getter setter) alist
(macroexp-let2 nil p (if (member testfn '(nil 'eq #'eq)) (macroexp-let2 nil p `(if (and ,testfn (not (eq ,testfn 'eq)))
`(assq ,k ,getter) (assoc ,k ,getter ,testfn)
`(assoc ,k ,getter ,testfn)) (assq ,k ,getter))
(funcall do (if (null default) `(cdr ,p) (funcall do (if (null default) `(cdr ,p)
`(if ,p (cdr ,p) ,default)) `(if ,p (cdr ,p) ,default))
(lambda (v) (lambda (v)