From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Nicolas Petton Newsgroups: gmane.emacs.devel Subject: Re: seq-some-p and nil Date: Tue, 08 Sep 2015 15:21:15 +0200 Message-ID: <87zj0xkpx0.fsf@petton.fr> References: <1441295429.4215.0@smtp.gmail.com> <87si6vl21r.fsf@petton.fr> <878u8k2vnp.fsf@udel.edu> <878u8i69ok.fsf@petton.fr> <674102d7-0e97-478a-af05-ca6d82c17c28@default> <87mvwym01x.fsf@petton.fr> <87h9n5mloa.fsf@petton.fr> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha256; protocol="application/pgp-signature" X-Trace: ger.gmane.org 1441718532 19722 80.91.229.3 (8 Sep 2015 13:22:12 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 8 Sep 2015 13:22:12 +0000 (UTC) Cc: Mark Oteiza , Drew Adams , emacs-devel@gnu.org To: Stefan Monnier Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Sep 08 15:21:58 2015 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 1ZZIqG-0001jy-5t for ged-emacs-devel@m.gmane.org; Tue, 08 Sep 2015 15:21:44 +0200 Original-Received: from localhost ([::1]:34039 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZZIqF-0004gg-Qx for ged-emacs-devel@m.gmane.org; Tue, 08 Sep 2015 09:21:43 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:45912) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZZIpu-0004ds-Ny for emacs-devel@gnu.org; Tue, 08 Sep 2015 09:21:23 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZZIpp-0003we-RX for emacs-devel@gnu.org; Tue, 08 Sep 2015 09:21:22 -0400 Original-Received: from out4-smtp.messagingengine.com ([66.111.4.28]:51712) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZZIpp-0003wT-Og for emacs-devel@gnu.org; Tue, 08 Sep 2015 09:21:17 -0400 Original-Received: from compute5.internal (compute5.nyi.internal [10.202.2.45]) by mailout.nyi.internal (Postfix) with ESMTP id 319B8208F0 for ; Tue, 8 Sep 2015 09:21:17 -0400 (EDT) Original-Received: from frontend1 ([10.202.2.160]) by compute5.internal (MEProxy); Tue, 08 Sep 2015 09:21:17 -0400 DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-sasl-enc :x-sasl-enc; s=smtpout; bh=UiJNhJq6lgpR6tC3ogLHTaOjeJE=; b=ZrcZY xwOhNmV6Toq+aN+hPjBUzW7WTF6flD6UP/jQEmkO0ssnwLzE4Do9nnnDnu1aHswW adIYjY4+n2Rs2vupVKhPoN5CIzy1v5d9oOs8sOq/s+Q+zXSu86swyrTgzCMq32ko N9/RjCnyB4v7gQHNr0ss/nf5Vovb/woPKXVQ5g= X-Sasl-enc: xw9B6hnMInoVcaSNCrs2xPi8c5ITiLbp4igAuEI5Odzj 1441718476 Original-Received: from blueberry (89-156-196-194.rev.numericable.fr [89.156.196.194]) by mail.messagingengine.com (Postfix) with ESMTPA id 6C5C6C00291; Tue, 8 Sep 2015 09:21:16 -0400 (EDT) In-Reply-To: User-Agent: Notmuch/0.19 (http://notmuchmail.org) Emacs/25.0.50.4 (x86_64-unknown-linux-gnu) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 66.111.4.28 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:189706 Archived-At: --=-=-= Content-Type: text/plain Stefan Monnier writes: > And using seq-some doesn't have the weird nil corner case. Just like CL's `find-if' and Scheme's `find', if one is looking for nil, and if `seq-find' is not supposed to return a boolean, then it's fine with me. You'd always have `seq-some' if it's an issue in a specific scenario anyway. > And defining seq-find as I did means it's always less efficient. It's ok, I think, for `seq-find' to reuse `seq-some'. You can't both want to remove code duplication and be as efficient as the code you are reusing. Nico --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 Comment: GPGTools - http://gpgtools.org iQEcBAEBCAAGBQJV7uDLAAoJECM1h6R8IHkQHjAIAMTLm8Y6Aax6QARM6SRkZQd3 DRByogWyYtf/95OsrrLr4HMqfkdXnzTLWYfFCK6jcWwdtW1q9Pwlw6DeJvM4ymLj 5WdpD7O3W42fjPgqV/nEuSh8f9AzuE4QDV1eO3L+bWxhCTOVSCbHNIm7kVG8ChRk 6QW1xf5OU488/lH2Rce83g64tHtmCZmErbNTofWZMQtriTKuR/0ZBLHhAWveexrT ZEAf4uhMn5+ZI1VbSKPPmlrVaSl4jM7sfNHbD4u4USg7yWu1QlWmVydoaLDOL9tq ArUKqBfjDEBBYnBtPrW7DaDmPNaGM9hkL+kHXBKibWW3ba0SFpSjFaRH90+LnDk= =UB7M -----END PGP SIGNATURE----- --=-=-=--