Re: [notmuch] [PATCH] Added regress option to tags iterator
authorCarl Worth <cworth@cworth.org>
Tue, 22 Dec 2009 03:16:49 +0000 (19:16 +1600)
committerW. Trevor King <wking@tremily.us>
Fri, 7 Nov 2014 17:35:55 +0000 (09:35 -0800)
bc/8b9de123d3b38dde7f7e372064434ac893d82b [new file with mode: 0644]

diff --git a/bc/8b9de123d3b38dde7f7e372064434ac893d82b b/bc/8b9de123d3b38dde7f7e372064434ac893d82b
new file mode 100644 (file)
index 0000000..fd6dc1f
--- /dev/null
@@ -0,0 +1,99 @@
+Return-Path: <cworth@cworth.org>\r
+X-Original-To: notmuch@notmuchmail.org\r
+Delivered-To: notmuch@notmuchmail.org\r
+Received: from localhost (localhost [127.0.0.1])\r
+       by olra.theworths.org (Postfix) with ESMTP id 3325B431FBD;\r
+       Mon, 21 Dec 2009 19:16:51 -0800 (PST)\r
+X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
+Received: from olra.theworths.org ([127.0.0.1])\r
+       by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)\r
+       with ESMTP id 9l2AYfs4A6eX; Mon, 21 Dec 2009 19:16:50 -0800 (PST)\r
+Received: from yoom.home.cworth.org (localhost [127.0.0.1])\r
+       by olra.theworths.org (Postfix) with ESMTP id 4DB44431FAE;\r
+       Mon, 21 Dec 2009 19:16:50 -0800 (PST)\r
+Received: by yoom.home.cworth.org (Postfix, from userid 1000)\r
+       id A5FC0254306; Mon, 21 Dec 2009 19:16:50 -0800 (PST)\r
+From: Carl Worth <cworth@cworth.org>\r
+To: Ruben Pollan <meskio@sindominio.net>, notmuch@notmuchmail.org\r
+In-Reply-To: <87r5qnol78.fsf@yoom.home.cworth.org>\r
+References: <20091126202347.GA16654@blackspot>\r
+       <1260364206-344-1-git-send-email-meskio@sindominio.net>\r
+       <20091209132446.GC23878@blackspot>\r
+       <877hsv6hbo.fsf@yoom.home.cworth.org>\r
+       <87r5qnol78.fsf@yoom.home.cworth.org>\r
+Date: Mon, 21 Dec 2009 19:16:49 -0800\r
+Message-ID: <87pr67ofz2.fsf@yoom.home.cworth.org>\r
+MIME-Version: 1.0\r
+Content-Type: multipart/signed; boundary="=-=-=";\r
+       micalg=pgp-sha1; protocol="application/pgp-signature"\r
+Subject: Re: [notmuch] [PATCH] Added regress option to tags iterator\r
+X-BeenThere: notmuch@notmuchmail.org\r
+X-Mailman-Version: 2.1.12\r
+Precedence: list\r
+List-Id: "Use and development of the notmuch mail system."\r
+       <notmuch.notmuchmail.org>\r
+List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
+       <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
+List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
+List-Post: <mailto:notmuch@notmuchmail.org>\r
+List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
+List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
+       <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
+X-List-Received-Date: Tue, 22 Dec 2009 03:16:51 -0000\r
+\r
+--=-=-=\r
+Content-Transfer-Encoding: quoted-printable\r
+\r
+On Mon, 21 Dec 2009 17:23:55 -0800, Carl Worth <cworth@cworth.org> wrote:\r
+>   New function               Corresponds to existing function (if any)\r
+>   ------------               -----------------------------------------\r
+>   move_to_first              <implicit in iterator creation>\r
+>   has_next           has_more\r
+>   move_to_next               advance\r
+>=20\r
+>   move_to_last               <none>\r
+>   has_previous               <none>\r
+>   move_to_previous   <none>\r
+>=20\r
+>   get                        get\r
+>=20\r
+> The semantics of those all seem clear enough to me. They provide what's\r
+> necessary for all three portions of a for loop, (in either direction),\r
+\r
+Except that they don't. :-P\r
+\r
+We don't want has_next and has_previous but something more like "has\r
+current", (perhaps to pair with get_current?).\r
+\r
+> The only downside is that the function names are a bit long in some\r
+> cases, but I'm willing to live with that until someone comes up with\r
+> better.\r
+\r
+One option is to just drop the "move_ " prefix. Then everything will be\r
+a two-word function. So the new proposal is:\r
+\r
+to_first\r
+has_current\r
+to_next\r
+\r
+to_last\r
+has_current\r
+to_previous\r
+\r
+get_current\r
+\r
+Better?\r
+\r
+=2DCarl\r
+\r
+--=-=-=\r
+Content-Type: application/pgp-signature\r
+\r
+-----BEGIN PGP SIGNATURE-----\r
+Version: GnuPG v1.4.10 (GNU/Linux)\r
+\r
+iD8DBQFLMDoi6JDdNq8qSWgRAvYUAJ0VcESuFmzvVPz34uybiZ5dTjW0SwCffKLg\r
+JS5n3wBuBsFDHyCgi2bRIFk=\r
+=Aj1I\r
+-----END PGP SIGNATURE-----\r
+--=-=-=--\r