From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.devel Subject: Re: emacs-25 2460cfa: * doc/lispref/lists.texi (Association Lists): Document 'alist-get'. Date: Tue, 19 Jan 2016 19:45:55 +0200 Message-ID: <83oachbgz0.fsf@gnu.org> References: <20160116143238.27391.97533@vcs.savannah.gnu.org> <8737ttx5dm.fsf@web.de> Reply-To: Eli Zaretskii NNTP-Posting-Host: plane.gmane.org X-Trace: ger.gmane.org 1453225566 6727 80.91.229.3 (19 Jan 2016 17:46:06 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 19 Jan 2016 17:46:06 +0000 (UTC) Cc: emacs-devel@gnu.org To: Michael Heerdegen Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Jan 19 18:46:05 2016 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1aLaM0-0008Cd-TX for ged-emacs-devel@m.gmane.org; Tue, 19 Jan 2016 18:46:05 +0100 Original-Received: from localhost ([::1]:38589 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aLaM0-00059a-Ae for ged-emacs-devel@m.gmane.org; Tue, 19 Jan 2016 12:46:04 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:44024) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aLaLn-00059H-O0 for emacs-devel@gnu.org; Tue, 19 Jan 2016 12:45:52 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aLaLj-0002bF-BC for emacs-devel@gnu.org; Tue, 19 Jan 2016 12:45:51 -0500 Original-Received: from fencepost.gnu.org ([2001:4830:134:3::e]:34567) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aLaLj-0002b9-7m; Tue, 19 Jan 2016 12:45:47 -0500 Original-Received: from 84.94.185.246.cable.012.net.il ([84.94.185.246]:2244 helo=HOME-C4E4A596F7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_128_CBC_SHA1:128) (Exim 4.82) (envelope-from ) id 1aLaLi-0004bG-ID; Tue, 19 Jan 2016 12:45:47 -0500 In-reply-to: <8737ttx5dm.fsf@web.de> (message from Michael Heerdegen on Tue, 19 Jan 2016 10:53:09 +0100) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:198372 Archived-At: > From: Michael Heerdegen > Cc: Eli Zaretskii > Date: Tue, 19 Jan 2016 10:53:09 +0100 > > > +@defun alist-get key value &optional default > > +This function is like @code{assq}, but instead of returning the entire > > +association for @var{key}, @code{(@var{key} . @var{value})}, it > > +returns just the @var{value}. It returns @var{default} if @var{key} > > +is not found in @var{alist}, defaulting to @code{nil} if @var{default} > > +is omitted. > > +@end defun > > Should we add that it is also a valid place expression ("setf'able")? Or > to the docstring? That fact doesn't seem to be discoverable at all now. I don't know -- should we? I didn't find any other function for which we say something like that, so saw no reason to single this one out. Did I miss something? In any case, if it's so important to mention that, why doesn't the function's doc string make a point of doing so? Or maybe I didn't understand the doc string (do you?).