From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: Paul Eggert Newsgroups: gmane.emacs.devel Subject: Re: Emacs regexp scan (Sep 29) Date: Sat, 5 Oct 2019 12:19:16 -0700 Organization: UCLA Computer Science Department Message-ID: <2831f530-b702-50e0-e494-8620d5a0fdb5@cs.ucla.edu> References: <1697CA97-B2E6-4202-B14D-99DCF93954FD@acm.org> <02405f0d-788f-1b87-0269-b06eb2d67ff8@cs.ucla.edu> <83zhif4nq6.fsf@gnu.org> <6cf4485e-3d94-ce92-6342-d83cdc7f95d7@cs.ucla.edu> <83k19j4fw3.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: quoted-printable Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="183678"; mail-complaints-to="usenet@blaine.gmane.org" User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.8.0 Cc: mattiase@acm.org, emacs-devel@gnu.org To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sat Oct 05 21:20:04 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.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1iGpb0-000lcW-PU for ged-emacs-devel@m.gmane.org; Sat, 05 Oct 2019 21:20:02 +0200 Original-Received: from localhost ([::1]:58498 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1iGpaz-0002u9-JH for ged-emacs-devel@m.gmane.org; Sat, 05 Oct 2019 15:20:01 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:35297) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1iGpaN-0002ty-T2 for emacs-devel@gnu.org; Sat, 05 Oct 2019 15:19:24 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1iGpaM-0006M5-J0 for emacs-devel@gnu.org; Sat, 05 Oct 2019 15:19:23 -0400 Original-Received: from zimbra.cs.ucla.edu ([131.179.128.68]:45590) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1iGpaL-0005v2-1V; Sat, 05 Oct 2019 15:19:21 -0400 Original-Received: from localhost (localhost [127.0.0.1]) by zimbra.cs.ucla.edu (Postfix) with ESMTP id ED5BD1605B7; Sat, 5 Oct 2019 12:19:17 -0700 (PDT) Original-Received: from zimbra.cs.ucla.edu ([127.0.0.1]) by localhost (zimbra.cs.ucla.edu [127.0.0.1]) (amavisd-new, port 10032) with ESMTP id FE0g6enEQ53l; Sat, 5 Oct 2019 12:19:17 -0700 (PDT) Original-Received: from localhost (localhost [127.0.0.1]) by zimbra.cs.ucla.edu (Postfix) with ESMTP id 364D31605B9; Sat, 5 Oct 2019 12:19:17 -0700 (PDT) X-Virus-Scanned: amavisd-new at zimbra.cs.ucla.edu Original-Received: from zimbra.cs.ucla.edu ([127.0.0.1]) by localhost (zimbra.cs.ucla.edu [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id U7F8Ha7mNyNO; Sat, 5 Oct 2019 12:19:17 -0700 (PDT) Original-Received: from [192.168.1.9] (cpe-23-242-74-103.socal.res.rr.com [23.242.74.103]) by zimbra.cs.ucla.edu (Postfix) with ESMTPSA id F2DC71605B7; Sat, 5 Oct 2019 12:19:16 -0700 (PDT) In-Reply-To: <83k19j4fw3.fsf@gnu.org> Content-Language: en-US X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x [fuzzy] X-Received-From: 131.179.128.68 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.23 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:240629 Archived-At: On 10/5/19 3:59 AM, Eli Zaretskii wrote: > The text in the manual says: >=20 > To include a =E2=80=98-=E2=80=99, write =E2=80=98-=E2=80=99 as the f= irst or last character of the > character alternative, or as the upper bound of a range. That quote is from an older version of the manual, which was amended afte= r some=20 discussion on this very point. The manual now distinguishes more carefull= y=20 between what's recommended, and what's valid even though it may cause con= fusion.=20 The manual now recommends putting literal '-' at the end and says that pu= tting=20 it elsewhere is not the best style even when it is valid. I take your point about not modifying Emacs just for the fun of it. Howev= er,=20 when bugs are being fixed, it's OK if the person doing the fix takes the=20 opportunity to make nearby code clearer, as the added clarity can increas= e the=20 probability of the fix being correct and can simplify later maintenance.=20 Although one can go overboard in the process and it's sometimes better to= leave=20 code alone even when it is confusing, generally speaking we should delega= te=20 these minor decisions to whoever's actually doing the work, in order to=20 encourage bug-fixers rather than throw cold water on them.