bug-grep
[Top][All Lists]
Advanced

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

bug#19738: How did [a-z] match é?


From: Eric Blake
Subject: bug#19738: How did [a-z] match é?
Date: Sat, 31 Jan 2015 15:25:29 -0700
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.4.0

tag 19738 notabug
thanks

On 01/30/2015 06:44 PM, James Calfee wrote:
> http://stackoverflow.com/questions/28247204/how-did-a-z-match-%C3%A9

Rather than making us chase a link, how about pasting the content of
your question directly in your mail.

At any rate, the answer to the question in your subject line is that
your current locale is set up to include letters outside of the 26 ascii
bytes.  Run with LC_ALL=C in the environment to get the well-defined
behavior you seem to want, and note that POSIX states that range
expressions in regular expressions are undefined in non-C locales,
precisely because some tools use all collation elements that 'sort'
would place in the range, while other tools use 'rational range
expression' and treat the range as if it were ASCII instead of the
current locale.

This is not a bug in coreutils, so I'm closing the tracker bug, but do
feel free to make further comments or questions.


-- 
Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

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