[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Difference between \\w and [:word:]?
From: |
Eric Abrahamsen |
Subject: |
Re: Difference between \\w and [:word:]? |
Date: |
Fri, 08 Jun 2018 08:05:44 -0700 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux) |
Yuri Khan <yurivkhan@gmail.com> writes:
> On Fri, Jun 8, 2018 at 4:17 PM Robert Pluim <rpluim@gmail.com> wrote:
>
>> > It definitely felt a little weird writing something like
>> > "\\w[[:word:]-']+", where we're required to use two different notations
>> > for the same match.
>> >
>>
>> Nothing prevents you from writing
>>
>> [[:word:]][[:word:]-']+
>
> Or even
>
> (rx wordchar (any wordchar ?- ?'))
I know, I know -- there are many ways to skin this cat, and for some
reason I went straight for one that didn't work. Thanks to all for the
other suggestions.
Eric