[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: :alnum: broken?

From: Paul Eggert
Subject: Re: :alnum: broken?
Date: Fri, 21 Feb 2020 17:09:20 -0800
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.5.0

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 $?

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.)

reply via email to

[Prev in Thread] Current Thread [Next in Thread]