bug-bash
[Top][All Lists]
Advanced

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

Re: Case modification fails for Unicode characters


From: Dennis Williamson
Subject: Re: Case modification fails for Unicode characters
Date: Thu, 12 Jul 2012 19:46:35 -0500

On Thu, Jul 12, 2012 at 1:57 PM, DJ Mills <danielmills1@gmail.com> wrote:
> On Thu, Jul 12, 2012 at 2:19 PM, Dennis Williamson
> <dennistwilliamson@gmail.com> wrote:
>> s=łódź; echo "${s^^} ${s~~}"'
>> łóDź ŁÓDŹ
>>
>> The to-upper and the undocumented toggle operators should produce
>> identical output in this situation, but only the toggle works
>> correctly.
>>
>> This is in en_US.UTF-8, but also reported in pl_PL.utf-8. In Bash
>> 4.2.24 and Bash 4.0.33.
>>
>> --
>> Visit serverfault.com to get your system administration questions answered.
>>
>
> I get the same result with:
> » echo "$s" | tr '[:lower:]' '[:upper:]'
> łóDź
>
> » locale
> LANG=en_US.UTF-8
> LC_CTYPE="en_US.UTF-8"
> LC_NUMERIC="en_US.UTF-8"
> LC_TIME="en_US.UTF-8"
> LC_COLLATE="en_US.UTF-8"
> LC_MONETARY="en_US.UTF-8"
> LC_MESSAGES="en_US.UTF-8"
> LC_PAPER="en_US.UTF-8"
> LC_NAME="en_US.UTF-8"
> LC_ADDRESS="en_US.UTF-8"
> LC_TELEPHONE="en_US.UTF-8"
> LC_MEASUREMENT="en_US.UTF-8"
> LC_IDENTIFICATION="en_US.UTF-8"
> LC_ALL=
>
>
> This is a locale issue, and has nothing to do with bash itself...


That's partly true except that ~~ works.

-- 
Visit serverfault.com to get your system administration questions answered.



reply via email to

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