From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from localhost (localhost [127.0.0.1]) by arlo.cworth.org (Postfix) with ESMTP id 53BD66DE0AAB for ; Wed, 18 Jan 2017 13:01:35 -0800 (PST) X-Virus-Scanned: Debian amavisd-new at cworth.org X-Spam-Flag: NO X-Spam-Score: -0.005 X-Spam-Level: X-Spam-Status: No, score=-0.005 tagged_above=-999 required=5 tests=[AWL=0.006, SPF_PASS=-0.001, T_RP_MATCHES_RCVD=-0.01] autolearn=disabled Received: from arlo.cworth.org ([127.0.0.1]) by localhost (arlo.cworth.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id TgQuaOuvWJKb for ; Wed, 18 Jan 2017 13:01:34 -0800 (PST) Received: from fethera.tethera.net (fethera.tethera.net [198.245.60.197]) by arlo.cworth.org (Postfix) with ESMTPS id 55C336DE00BD for ; Wed, 18 Jan 2017 13:01:34 -0800 (PST) Received: from remotemail by fethera.tethera.net with local (Exim 4.84_2) (envelope-from ) id 1cTxLq-00080x-2x; Wed, 18 Jan 2017 16:01:02 -0500 Received: (nullmailer pid 15105 invoked by uid 1000); Wed, 18 Jan 2017 21:01:29 -0000 From: David Bremner To: Jani Nikula , notmuch@notmuchmail.org Subject: Re: [Patch v2] lib: regexp matching in 'subject' and 'from' In-Reply-To: <877f5scewx.fsf@nikula.org> References: <1467034387-16885-1-git-send-email-david@tethera.net> <20161114214651.19770-1-david@tethera.net> <877f5scewx.fsf@nikula.org> Date: Wed, 18 Jan 2017 17:01:29 -0400 Message-ID: <871sw0f5g6.fsf@rocinante.cs.unb.ca> MIME-Version: 1.0 Content-Type: text/plain X-BeenThere: notmuch@notmuchmail.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: "Use and development of the notmuch mail system." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 18 Jan 2017 21:01:35 -0000 Jani Nikula writes: > I played around with this a bit, and it seemed to work. Unsurprisingly, > getting the quoting right was the hardest part. Even though I know how > the stuff works under the hood, it took me a while to realize that you > have to use 're:"subject:"' to make it work. (I kept > trying 're:subject:""'.) I don't know if there's > anything we could really do about this. > I _think_ we could add distinct prefixes at the xapian level for each regex-prefix. That opens the can of worms of naming them eg re-subject: and re-from:. I'm not sure about the added complexity, but I think it's a matter of adding an extra argument to the field processor constructor. d