bug-bash
[Top][All Lists]
Advanced

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

Re: Suggestion of wording for portion of man page


From: Chet Ramey
Subject: Re: Suggestion of wording for portion of man page
Date: Mon, 20 Jan 2025 12:43:30 -0500
User-agent: Mozilla Thunderbird

On 1/18/25 7:15 AM, Félix Hauri wrote:

hobbit:~$ var='garçon'
hobbit:~$ echo "${var^^}"
GARÇON

But, UTF-8 is a kind of nightmare:

   var1=$'gar\303\247on'
   var2=$'garc\314\247on'

Yes, NFD vs NFC is confusing. But POSIX is pretty clear that these are
different characters that happen to have the same graphical
representation and should be treated accordingly:

"Matching shall be based on the bit pattern used for encoding the
character, not on the graphic representation of the character."

The burden is, unfortunately, on the application writer.

--
``The lyf so short, the craft so long to lerne.'' - Chaucer
                 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://tiswww.cwru.edu/~chet/

Attachment: OpenPGP_signature.asc
Description: OpenPGP digital signature


reply via email to

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