GNU bug report logs - #27584
26.0.50; alist-get: Add optional arg TESTFN

Previous Next

Package: emacs;

Reported by: Tino Calancha <tino.calancha <at> gmail.com>

Date: Wed, 5 Jul 2017 03:24:02 UTC

Severity: wishlist

Found in version 26.0.50

Done: Tino Calancha <tino.calancha <at> gmail.com>

Bug is archived. No further changes may be made.

Full log


Message #148 received at 27584 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Nicolas Petton <nicolas <at> petton.fr>
Cc: 27584 <at> debbugs.gnu.org, monnier <at> iro.umontreal.ca, tino.calancha <at> gmail.com
Subject: Re: bug#27584: 26.0.50; alist-get: Add optional arg TESTFN
Date: Tue, 01 Aug 2017 21:53:29 +0300
> From: Nicolas Petton <nicolas <at> petton.fr>
> Cc: tino.calancha <at> gmail.com, 27584 <at> debbugs.gnu.org, monnier <at> iro.umontreal.ca
> Date: Tue, 01 Aug 2017 18:49:43 +0200
> 

A few comments:

> * doc/lispref/lists.texi: Document the change.

This should state the node in parentheses (as if it were a function).

> +@defun rassoc value alist &optional testfn
>  This function returns the first association with value @var{value} in
> -@var{alist}.  It returns @code{nil} if no association in @var{alist} has
> -a @sc{cdr} @code{equal} to @var{value}.
> +@var{alist}, comparing @var{value} against the alist elements using
> +@var{testfn} if non-nil, or @code{equal} if nil (@pxref{Equality

The "if nil" part is confusing, because you actually mean "if
@var{testfn} is nil".

Also, "nil" should be in @code.

> +Predicates}).  It returns @code{nil} if no association in @var{alist}
> +has a @sc{cdr} equal to @var{value}.

That reference to cdr is a surprise.  the original description talked
about cdr right from the start, but the new one doesn't.

Thanks.




This bug report was last modified 7 years and 354 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.