From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Alan Mackenzie Newsgroups: gmane.emacs.devel Subject: Re: Question on pcase Date: Sat, 24 Oct 2015 19:28:58 +0000 Message-ID: <20151024192858.GC2731@acm.fritz.box> References: <83r3kmrtat.fsf@gnu.org> <87r3kl22zk.fsf@web.de> <837fmdzpf2.fsf@gnu.org> <87oafp659p.fsf@web.de> <831tclzly9.fsf@gnu.org> <87fv115t20.fsf@web.de> <20151024090146.GA1849@acm.fritz.box> <878u6spgmp.fsf@gmx.net> <20151024174719.GB2731@acm.fritz.box> <87ziz8nkue.fsf@gmx.net> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1445714866 9891 80.91.229.3 (24 Oct 2015 19:27:46 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 24 Oct 2015 19:27:46 +0000 (UTC) Cc: Michael Heerdegen , Eli Zaretskii , Oleh Krehel , Emacs Development To: Stephen Berman Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sat Oct 24 21:27:36 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 1Zq4TV-0000cs-Oy for ged-emacs-devel@m.gmane.org; Sat, 24 Oct 2015 21:27:33 +0200 Original-Received: from localhost ([::1]:45420 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Zq4TV-0006C9-1o for ged-emacs-devel@m.gmane.org; Sat, 24 Oct 2015 15:27:33 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:50517) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Zq4TI-0006Af-Kg for emacs-devel@gnu.org; Sat, 24 Oct 2015 15:27:21 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Zq4TF-0005mt-FP for emacs-devel@gnu.org; Sat, 24 Oct 2015 15:27:20 -0400 Original-Received: from mail.muc.de ([193.149.48.3]:63866) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Zq4TF-0005mf-2S for emacs-devel@gnu.org; Sat, 24 Oct 2015 15:27:17 -0400 Original-Received: (qmail 76473 invoked by uid 3782); 24 Oct 2015 19:27:15 -0000 Original-Received: from acm.muc.de (p5B1464C0.dip0.t-ipconnect.de [91.20.100.192]) by colin.muc.de (tmda-ofmipd) with ESMTP; Sat, 24 Oct 2015 21:27:14 +0200 Original-Received: (qmail 3218 invoked by uid 1000); 24 Oct 2015 19:28:58 -0000 Content-Disposition: inline In-Reply-To: <87ziz8nkue.fsf@gmx.net> User-Agent: Mutt/1.5.23 (2014-03-12) X-Delivery-Agent: TMDA/1.1.12 (Macallan) X-Primary-Address: acm@muc.de X-detected-operating-system: by eggs.gnu.org: FreeBSD 9.x X-Received-From: 193.149.48.3 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:192581 Archived-At: Hello, Stephen. On Sat, Oct 24, 2015 at 09:10:49PM +0200, Stephen Berman wrote: > On Sat, 24 Oct 2015 17:47:19 +0000 Alan Mackenzie wrote: > >> > ;; This is a pattern form that allows you to match a pattern PAT > >> > ;; against an _arbitrary_ expression EXP. This is not special, > >> > -;; matching PAT is done as you have learned, just against the EXP you > >> > +;; matching PAT is done as you have learned, just on the EXP you > >> > ;; specify there, and not the EXPRESSION given to pcase at top level. > >> Why replace "against" with "on" here but not in the preceding line? I > >> think "against" is usual in this context. A somewhat better formulation > >> is this, IMO: "The only difference from the pattern matching you have > >> learned is that PAT is matched against the EXP you specify here..." > > Oh, no! This is complicated, too. > It doesn't strike me as more complicated than the original, just a bit > less stilted (to my ears). Sorry for that. I meant the _topic_ is complicated. > > Perhaps the best preposition for > > "match" here is "with", on the grounds that harmony is expected rather > > than a fight. You might match one sporting team against another, but > > you'd match the colour of an item of clothing with that of another. Or > > something like that. > "Match with" sounds out of place here. I think "match against" is > pretty much standard in the context of pattern matching in formal or > programming languages; cf. these quotes (among many similar) from > Friedl's _Mastering Regular Expressions_ (3rd ed): Maybe. I confess here to being personally irritated by "match against". I don't know why. But I honestly think it's time for our discussion to cease. We've unwittingly descended into bikeshedding, and we're not going to be helping Michael Heerdegen much with it. But thanks for the discussion anyway! [ Paragraphs snipped, but read and largely accepted. ] > Steve Berman -- Alan Mackenzie (Nuremberg, Germany).