From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Michael Heerdegen Newsgroups: gmane.emacs.devel Subject: Re: Replace trivial pcase occurrences in the Emacs sources Date: Tue, 06 Nov 2018 00:06:25 +0100 Message-ID: <87va5b9lam.fsf@web.de> References: <83tvlcsnee.fsf@gnu.org> <86mur137n8.fsf@gmail.com> <20181029130132.GB4195@ACM> <20181029134722.GC4195@ACM> <87y3aftklz.fsf@web.de> <87in1jt4ll.fsf@web.de> <87muqojnab.fsf@web.de> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: blaine.gmane.org 1541459380 27016 195.159.176.226 (5 Nov 2018 23:09:40 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Mon, 5 Nov 2018 23:09:40 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux) Cc: emacs-devel@gnu.org To: Stefan Monnier Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Nov 06 00:09:35 2018 Return-path: Envelope-to: ged-emacs-devel@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 1gJnzz-0006w7-LS for ged-emacs-devel@m.gmane.org; Tue, 06 Nov 2018 00:09:35 +0100 Original-Received: from localhost ([::1]:37985 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gJo26-0001R2-2L for ged-emacs-devel@m.gmane.org; Mon, 05 Nov 2018 18:11:46 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:59564) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gJo1x-0001Qi-Fr for emacs-devel@gnu.org; Mon, 05 Nov 2018 18:11:40 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gJnxC-0005gc-Qf for emacs-devel@gnu.org; Mon, 05 Nov 2018 18:06:46 -0500 Original-Received: from mout.web.de ([212.227.15.14]:33355) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1gJnxA-0005aM-Sf for emacs-devel@gnu.org; Mon, 05 Nov 2018 18:06:42 -0500 Original-Received: from drachen.dragon ([94.218.210.177]) by smtp.web.de (mrweb001 [213.165.67.108]) with ESMTPSA (Nemesis) id 0LpfFO-1fqX8U2Y8k-00fRe1; Tue, 06 Nov 2018 00:06:28 +0100 Original-Received: from drachen.dragon ([94.218.210.177]) by smtp.web.de (mrweb001 [213.165.67.108]) with ESMTPSA (Nemesis) id 0LpfFO-1fqX8U2Y8k-00fRe1; Tue, 06 Nov 2018 00:06:28 +0100 In-Reply-To: (Stefan Monnier's message of "Sun, 04 Nov 2018 23:49:48 -0500") X-Provags-ID: V03:K1:04CfxlYHRN0ZbqKnSBpcearUdugTwpOGi0NjbZWiCPDAdoH43tx equOex9m1eje5T/LVmSXmSIlcS3YrLGL3CmnAPinBOO2lBeocbMBW9UsKocv7j5wXtC7zP5 6By87arfyATF5m1dkjfG6hBB0CKAlNopQnLu77ZOC00hUdIf0nqbWybLyq+HpHBv0/JVPeO tRgZneJc9MZTmwMuumZxg== X-UI-Out-Filterresults: notjunk:1;V01:K0:TzQxcc/VUHk=:n9gWYzTxgKXz2BxU3jQbO+ CzlRcKP2nUuy1/ZJubSm9wb87fXljx2qAlyds5W9t81n5iAoKbZhAL7gp3/lq+9GiJ3eaXR/f MYYRePHmcjw4SHDMsSP0T/xYcnQQn/+Vcfi3UqPdv5gTiXLhYG7P+8WCFDgp/l2wYXFnjxUT1 tuZY9v1mJ6O2V8hW9ebMRoQFpsOuWV6wuA1vifZgw9TEaBR7NyWOW2JMiB6WfLBKHA1cU/ju+ FKrVIB369h6+NHueXt+nnm2kzlxvvCJTZ+HUoAwN2rR4/h6GsHK288J6lSzJkGDbLbGqbTMy6 26BcEj66csfqnGBaiJxahPzxBHr8HLXXYQSMmSLZWEOCyM9AAc/5Zn4JtDSD8D0Pp4kp356hC /EALXVcQLuFXMlA/nGWEZv1C2UZNWJbKQtxuKPU3FcTw+G9i1gAGukx15vbH2AqfaUnvYhBYa 2dMaanidJ8cR4iaIP4zknBIDs+dk2d8yluR1lOLQ6ztzdWI4KycANch/7gBMgpgcmJyu7Dwxr jsqaJTTknoQMAKKlPSD3HBMFfJAZF9fnIN8f4dZjHC9jcH5GODQLO5lHHC45bswVLkqt4MTtu 1uBX8Nbe4DaFeLL8nzg/7esf0WiELKoWGAN7TUga5WGVH+odttfSyI1CTZirscSw+cxpTMcKt IbM37pi+GtOWEjBAhG2CtPIzrH4YMUlE66N1m9hd615anxvVgC6xKAo/+tPETzu/wKSBGo3A2 Qy755No69KZKJWqTGFAnrLYlbAS16zvR+uqQ3+dgeDYlVbpSKdhjRMpjWtBb4rfo1Qq9TY7F X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 212.227.15.14 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.21 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" Xref: news.gmane.org gmane.emacs.devel:231031 Archived-At: Stefan Monnier writes: > >> But some of the preds and guards of other branches (both before and > >> after the one of BODY1) may also be run before getting to BODY1. > > > > Does that imply that we also should remove sentences like these from > > the manual (last line): > > > > @item (and @var{pattern1}@dots{}) > > Attempts to match @var{pattern1}@dots{}, in order, > > until one of them fails to match. > > In that case, @code{and} likewise fails to match, > > and the rest of the sub-patterns are not tested. > > No, that one sounds fine. > Why do you think it's inconsistent with what I said? I wondered if what you said about the preds and guards of other branches is also true about preds and guards in other "branches" in ors and ands. With other words, I wonder when we say > > In that case, @code{and} likewise fails to match, > > and the rest of the sub-patterns are not tested. if what users expects to be the "rest" of subpatterns is always the patterns lexically following the one that failed. Are patterns in or and and always tested in order? And, if these include preds or guards, always exactly once? Michael.