From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: =?utf-8?Q?Mattias_Engdeg=C3=A5rd?= Newsgroups: gmane.emacs.devel Subject: Re: [ELPA] New package: xr Date: Fri, 1 Mar 2019 14:39:24 +0100 Message-ID: <5904ECC1-8E45-49FB-B457-2924519733DA@acm.org> References: <875zt5feys.fsf@web.de> <23E9F007-5B84-45C6-9933-5A1220058CAA@acm.org> <87o96xdup3.fsf@web.de> <99EEC0DC-3E76-4CC7-80D7-B6ADF480C818@acm.org> Mime-Version: 1.0 (Mac OS X Mail 12.2 \(3445.102.3\)) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="143956"; mail-complaints-to="usenet@blaine.gmane.org" Cc: emacs-devel To: Stefan Monnier Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Mar 01 14:39:42 2019 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([209.51.188.17]) by blaine.gmane.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1gziO4-000bHG-Sf for ged-emacs-devel@m.gmane.org; Fri, 01 Mar 2019 14:39:41 +0100 Original-Received: from localhost ([127.0.0.1]:37977 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gziO3-0008LE-R9 for ged-emacs-devel@m.gmane.org; Fri, 01 Mar 2019 08:39:39 -0500 Original-Received: from eggs.gnu.org ([209.51.188.92]:58461) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gziNw-0008JT-B5 for emacs-devel@gnu.org; Fri, 01 Mar 2019 08:39:33 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gziNv-0004TR-Iy for emacs-devel@gnu.org; Fri, 01 Mar 2019 08:39:32 -0500 Original-Received: from mail231c50.megamailservers.eu ([91.136.10.241]:59210 helo=mail37c50.megamailservers.eu) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1gziNu-0004RZ-Vs for emacs-devel@gnu.org; Fri, 01 Mar 2019 08:39:31 -0500 X-Authenticated-User: mattiase@bredband.net DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=megamailservers.eu; s=maildub; t=1551447568; bh=I0jDTTLfubEZUK+A1dsUbvCqMWfh8QJMdsqfBqHJG+g=; h=Subject:From:In-Reply-To:Date:Cc:References:To:From; b=MVwocVs/QTRkheELMdlZjjyX4cCeGfl96s8bC+hQmglyN6XKiroVa6Dgw26LETmJo fcKzafW3o1Uz8WMC/w3NzlJP9wxOoFE8iOV2zvCDnTSDDI9fF3FAc7Q+aHEOwcA+7/ ea+M/yTDt6EUfG4Ri+LXaJctdoYbA7WrQxufbmTY= Feedback-ID: mattiase@acm.or Original-Received: from [192.168.0.4] (c83-251-8-17.bredband.comhem.se [83.251.8.17]) (authenticated bits=0) by mail37c50.megamailservers.eu (8.14.9/8.13.1) with ESMTP id x21DdOEl018321; Fri, 1 Mar 2019 13:39:28 +0000 In-Reply-To: X-Mailer: Apple Mail (2.3445.102.3) X-CTCH-RefID: str=0001.0A0B0201.5C793610.0093, ss=1, re=0.000, recu=0.000, reip=0.000, cl=1, cld=1, fgs=0 X-CTCH-VOD: Unknown X-CTCH-Spam: Unknown X-CTCH-Score: 0.000 X-CTCH-Flags: 0 X-CTCH-ScoreCust: 0.000 X-CSC: 0 X-CHA: v=2.3 cv=J+uEEjvS c=1 sm=1 tr=0 a=NAHmi3I8mP0S/Y8gRKeQyA==:117 a=NAHmi3I8mP0S/Y8gRKeQyA==:17 a=kj9zAlcOel0A:10 a=iRZporoAAAAA:8 a=CpABsItW9duKjqE2O2IA:9 a=CjuIK1q_8ugA:10 a=NOBgFS-JBQ2l-kSd6-zu:22 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no timestamps) [generic] X-Received-From: 91.136.10.241 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:233724 Archived-At: 1 mars 2019 kl. 00.06 skrev Stefan Monnier : > I'm definitely in favor of using the standard * + and ? They are suggestive but I find `?' a bit on the hacky side. For = instance, you can't break the line after the operator, since it requires = a space following. >> any char in >=20 > I think I prefer `char` or `in`. Interestingly, (not (any ...)) and (not (in ...)) are valid, but (not = (char ...)) isn't (although there is `not-char'). Another implementation leak: since `any' is also an alias for = `not-newline', `char' and `in' are as well: (rx any char in) =3D> "..." >> line-start bol >> line-end eol >> string-start buffer-start bos bot >> string-end buffer-end eos eot >> word-start bow >> word-end eow >=20 > I like the boX/eoX nomenclature. >=20 > The main benefit of RX is to make the structure more visible, and the > main downside is to make regexp more verbose, so I think short > identifiers are preferable. There is definitely merit to that, although I also have sympathy for the = verbosity preferred by others. Lisp seems to cope with long identifiers better than most other = languages (dashes permitted, easy line breaking). I'm leaning towards giving xr a brief and verbose options, and let the = default be in the middle somewhere. >> sequence seq and : >=20 > I'm strongly opposed to `and` because that should mean the > conjunction/intersection of two regexps (i.e. a string matches it only > if it matches both sub-regexps) rather than the sequential = concatenation. > [ lex.el supports such intersections. ] Strongly agreed!