Re: square bracket vs. curly brace character ranges

2012-10-02 Thread Bob Proulx
Linda Walsh wrote: > Chet Ramey wrote: > >http://lists.gnu.org/archive/html/bug-bash/2012-05/msg00086.html > >...Campaign For Rational Range Interpretation... > > The next version of bash will have a shell option to enable this > behavior. It's in the development snapshots if anyone wants to try >

Re: square bracket vs. curly brace character ranges

2012-10-02 Thread Linda Walsh
Chet Ramey wrote: http://lists.gnu.org/archive/html/bug-bash/2012-05/msg00086.html The above relies upon a hack to the algorithm -- use *USEFUL* hack in most cases, but still a hack. when I type locale I get: LANG=en_US.UTF-8 LC_CTYPE=en_US.UTF-8 LC_NUMERIC="en_US.UTF-8" LC_TIME="en_US.U

Re: square bracket vs. curly brace character ranges

2012-09-17 Thread Greg Wooledge
On Sat, Sep 15, 2012 at 06:12:24PM -0600, Bob Proulx wrote: > I don't know so I will ask. Isn't the problem endemic to glibc? Do > other libc's such as HP-UX or AIX or other have this same issue? I am > out of touch on the details of them these days. imadev:/tmp/greg$ uname -a HP-UX imadev B.10

Re: square bracket vs. curly brace character ranges

2012-09-16 Thread Aharon Robbins
Hi Bob, In article , Bob Proulx wrote: >Hi Arnold, > >Aharon Robbins wrote: >> You are ssuming here that everyone uses GLIBC. > >I don't know so I will ask. Isn't the problem endemic to glibc? Do >other libc's such as HP-UX or AIX or other have this same issue? I am >out of touch on the detai

Re: square bracket vs. curly brace character ranges

2012-09-15 Thread Bob Proulx
Hi Arnold, Aharon Robbins wrote: > You are ssuming here that everyone uses GLIBC. I don't know so I will ask. Isn't the problem endemic to glibc? Do other libc's such as HP-UX or AIX or other have this same issue? I am out of touch on the details of them these days. > Not so. The projects th

Re: square bracket vs. curly brace character ranges

2012-09-15 Thread Aharon Robbins
In article , Bob Proulx wrote: >Marcel Giannelia wrote: >> locale-dependent [a-c] suggests to me that the software should be >> changed to just do what people expect, especially since nothing is >> really lost by doing so. > >I know that some projects are doing just that. I don't know the plans

Re: square bracket vs. curly brace character ranges

2012-09-14 Thread Chet Ramey
On 9/14/12 4:48 PM, Bob Proulx wrote: >> The sheer number of threads we've got complaining about >> locale-dependent [a-c] suggests to me that the software should be >> changed to just do what people expect, especially since nothing is >> really lost by doing so. > > I know that some projects are

Re: square bracket vs. curly brace character ranges

2012-09-14 Thread Greg Wooledge
On Fri, Sep 14, 2012 at 02:48:21PM -0600, Bob Proulx wrote: > > $ ls [a-c] > > a A b B c > > The expression [a-c] is really like saying [aAbBc] in your active > locale. Using locale based character ranges outside of the C locale > is problematic and I always avoid them. It's even worse on so

Re: square bracket vs. curly brace character ranges

2012-09-14 Thread DJ Mills
On Fri, Sep 14, 2012 at 1:49 AM, Marcel Giannelia wrote: > I believe I've found an inconsistency in bash or its documentation. > > I know the fact that things like [a-c] are highly locale-dependent in > bash (doesn't mean I have to like it, but there it is). Fine. I've > learned to live with it.

Re: square bracket vs. curly brace character ranges

2012-09-14 Thread Bob Proulx
Marcel Giannelia wrote: > But the other day I was on a fresh install (hadn't set > LC_COLLATE=C yet, so I was in en_US.UTF-8), and this happened: > > $ ls > a A b B c C > $ ls {a..c} > a b c The above has nothing to do with file glob expansion. Using 'ls' there I think confuses the discu

square bracket vs. curly brace character ranges

2012-09-13 Thread Felix
I believe I've found an inconsistency in bash or its documentation. I know the fact that things like [a-c] are highly locale-dependent in bash (doesn't mean I have to like it, but there it is). Fine. I've learned to live with it. But the other day I was on a fresh install (hadn't set LC_COLLATE=C