From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Nicolas Petton Newsgroups: gmane.emacs.bugs Subject: bug#27584: 26.0.50; alist-get: Add optional arg TESTFN Date: Sun, 09 Jul 2017 21:18:01 +0200 Message-ID: <87eftp4dxy.fsf@strawberry> References: <87tw2rva7v.fsf@calancha-pc> <87mv8j6y1z.fsf@petton.fr> <87y3s2m76v.fsf@calancha-pc> <8760f562bo.fsf@petton.fr> <877ezk3g4p.fsf@calancha-pc> <874luovf7a.fsf@petton.fr> <87shi8tzkr.fsf@petton.fr> <8737a858so.fsf@petton.fr> <83wp7jl9uf.fsf@gnu.org> <83lgnzl7rl.fsf@gnu.org> <87inj3411g.fsf@petton.fr> <83a84fkv7i.fsf@gnu.org> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha256; protocol="application/pgp-signature" X-Trace: blaine.gmane.org 1499628013 20176 195.159.176.226 (9 Jul 2017 19:20:13 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sun, 9 Jul 2017 19:20:13 +0000 (UTC) Cc: tino.calancha@gmail.com, 27584@debbugs.gnu.org, monnier@iro.umontreal.ca To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sun Jul 09 21:20:09 2017 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dUHkX-00054O-9q for geb-bug-gnu-emacs@m.gmane.org; Sun, 09 Jul 2017 21:20:09 +0200 Original-Received: from localhost ([::1]:37168 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dUHkc-00016r-Rp for geb-bug-gnu-emacs@m.gmane.org; Sun, 09 Jul 2017 15:20:14 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:44204) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dUHjV-0000T4-By for bug-gnu-emacs@gnu.org; Sun, 09 Jul 2017 15:19:06 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dUHjS-0008Ef-6j for bug-gnu-emacs@gnu.org; Sun, 09 Jul 2017 15:19:05 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:56485) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1dUHjS-0008ES-2j for bug-gnu-emacs@gnu.org; Sun, 09 Jul 2017 15:19:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1dUHjR-0001qd-Pj for bug-gnu-emacs@gnu.org; Sun, 09 Jul 2017 15:19:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Nicolas Petton Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 09 Jul 2017 19:19:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 27584 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 27584-submit@debbugs.gnu.org id=B27584.14996278957051 (code B ref 27584); Sun, 09 Jul 2017 19:19:01 +0000 Original-Received: (at 27584) by debbugs.gnu.org; 9 Jul 2017 19:18:15 +0000 Original-Received: from localhost ([127.0.0.1]:59161 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dUHih-0001pf-28 for submit@debbugs.gnu.org; Sun, 09 Jul 2017 15:18:15 -0400 Original-Received: from petton.fr ([89.234.186.68]:56546) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dUHie-0001pR-TB for 27584@debbugs.gnu.org; Sun, 09 Jul 2017 15:18:13 -0400 In-Reply-To: <83a84fkv7i.fsf@gnu.org> DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=petton.fr; s=mail; t=1499627885; bh=aGgrQemnR4zeA60Hh1y5OsvmusGqtMUvnnqKn+hIhRE=; h=From:To:Cc:Subject:In-Reply-To:References:Date:Message-ID:MIME-Version:Content-Type; b=VsZMgeFehuOy3akw+k2yMGlWrg2Zq+P6bCAbjL7BFKHO6kbcT2dUHJFk9iVMRZtZyaagy7XQa4IMosdwArOuZBaU4gDkTyY3Lq5GcQjILZF/b8emFua0wmbfwHH0lAMgr2RvXuDaN8hFoHLSMY5ZKjBjVd9cz4hHbN3PVenJ6Eo= X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:134375 Archived-At: --=-=-= Content-Type: text/plain Eli Zaretskii writes: >> What solution did you have in mind? > > Something like this: > > FOR_EACH_TAIL (tail) > { > Lisp_Object car = XCAR (tail); > if (CONSP (car) > && (NILP (testfn) > ? (EQ (XCAR (car), key) || !NILP (Fequal (XCAR (car), key))) > : !NILP (call2 (testfn, XCAR (car), key)))) > return car; > } Thanks, it's indeed much better. --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQEcBAEBCAAGBQJZYoFpAAoJECM1h6R8IHkQFdsIANDny+OuzC6h+pqVkkJdU8wz XYSa+elihkd4UmnrbX+RBMJAsZQeARfiydD1MqyJlmVzqDPTypViK53W5HDzNO50 +tDiAtVbsKjMDD0mKNEm1BgqIFAd23/CNPWyzokY3W85HF6Khg2bEJcpJE4M2VXj Kq0ZPBfnLLcTECv7He1s3UoxuO/6N+Bu0MWGFuP0UH0s+sEj/u8dFI0QoyXhkM0j eZrnJln2byMDhrc8/VR6tW0wOd+lJBKL1lAuD2EUVc6gpVw/2NoBvmyKVes27yG/ kPwnlztXv7VbchYMcEaHRQExltwLuygntDEz4rP38QeoFg+D7rZcORmKofXSFaw= =N39j -----END PGP SIGNATURE----- --=-=-=--