From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.ciao.gmane.io!not-for-mail From: Paul Eggert Newsgroups: gmane.emacs.devel Subject: Re: :alnum: broken? Date: Fri, 21 Feb 2020 17:09:20 -0800 Organization: UCLA Computer Science Department Message-ID: <5fecc0e1-1ee2-5a89-9297-b0b9aa4a8e9c@cs.ucla.edu> References: <86wo8flqct.fsf@stephe-leake.org> <86sgj3ljf0.fsf@stephe-leake.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Injection-Info: ciao.gmane.io; posting-host="ciao.gmane.io:159.69.161.202"; logging-data="23476"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.5.0 To: Stephen Leake , emacs-devel Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Sat Feb 22 02:10:00 2020 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1j5JIu-0005zA-9R for ged-emacs-devel@m.gmane-mx.org; Sat, 22 Feb 2020 02:10:00 +0100 Original-Received: from localhost ([::1]:37922 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1j5JIt-0004rb-AH for ged-emacs-devel@m.gmane-mx.org; Fri, 21 Feb 2020 20:09:59 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:59579) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1j5JIO-0004Br-Rr for emacs-devel@gnu.org; Fri, 21 Feb 2020 20:09:29 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1j5JIN-0007De-Dy for emacs-devel@gnu.org; Fri, 21 Feb 2020 20:09:28 -0500 Original-Received: from zimbra.cs.ucla.edu ([131.179.128.68]:38792) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1j5JIN-0007DC-8l for emacs-devel@gnu.org; Fri, 21 Feb 2020 20:09:27 -0500 Original-Received: from localhost (localhost [127.0.0.1]) by zimbra.cs.ucla.edu (Postfix) with ESMTP id 9AE651600D0; Fri, 21 Feb 2020 17:09:24 -0800 (PST) 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 MJWKMwDJAwTQ; Fri, 21 Feb 2020 17:09:23 -0800 (PST) Original-Received: from localhost (localhost [127.0.0.1]) by zimbra.cs.ucla.edu (Postfix) with ESMTP id E19B01600D1; Fri, 21 Feb 2020 17:09:23 -0800 (PST) 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 WjU7-HFh00Jd; Fri, 21 Feb 2020 17:09:23 -0800 (PST) Original-Received: from Penguin.CS.UCLA.EDU (Penguin.CS.UCLA.EDU [131.179.64.200]) by zimbra.cs.ucla.edu (Postfix) with ESMTPSA id AF3551600D0; Fri, 21 Feb 2020 17:09:23 -0800 (PST) In-Reply-To: <86sgj3ljf0.fsf@stephe-leake.org> Content-Language: en-US X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x 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-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:245026 Archived-At: On 2/21/20 1:28 PM, Stephen Leake wrote: > I propose this patch to help others avoid the same mistake: Perhaps better yet would be for Emacs to do what GNU grep does: $ grep '[:space:]' grep: character class syntax is [[:space:]], not [:space:] $ echo $? 2 That is, GNU grep treats a bracket expression like '[:space:]' as an error, since it's inevitably a typo. (POSIX does not allow this behavior so the diagnostic is suppressed if POSIXLY_CORRECT is set.)