On 07/06/2023 15:16, Ulrich Mueller wrote:
Can this bug be closed? AFAICS it is fixed since coreutils-9.2.
Relevant commit:
https://git.savannah.gnu.org/cgit/coreutils.git/commit/src/printf.c?id=0925e8a0f413ecf9004153d89b312b385b20d0ee
Marked as done.
thanks!
Pádraig
Can this bug be closed? AFAICS it is fixed since coreutils-9.2.
Relevant commit:
https://git.savannah.gnu.org/cgit/coreutils.git/commit/src/printf.c?id=0925e8a0f413ecf9004153d89b312b385b20d0ee
On 2019/08/01 16:37, Paul Eggert wrote:
> Ulrich Mueller wrote:
>
>> Except for the surrogates
>> U+D800...U+DFFF, it looks like an arbitrary restriction
>>
>
> It's not entirely arbitrary. Because of the restriction, coreutils printf
> doesn't have to worry about what this command should
> On Fri, 02 Aug 2019, Paul Eggert wrote:
> It's not entirely arbitrary. Because of the restriction, coreutils
> printf doesn't have to worry about what this command should do:
> printf '\u0025d\n' 1 2
Seems quite obvious, it should do the same as these commands:
printf '\045d\n' 1 2
Ulrich Mueller wrote:
Except for the surrogates
U+D800...U+DFFF, it looks like an arbitrary restriction
It's not entirely arbitrary. Because of the restriction, coreutils printf
doesn't have to worry about what this command should do:
printf '\u0025d\n' 1 2
Does this print a single line
> On Thu, 01 Aug 2019, Pádraig Brady wrote:
> I agree this is a bit surprising.
Indeed, it most certainly violates the principle of least surprise.
Especially, it means that a shell script that will run in bash won't
run in a shell that doesn't have a built-in printf.
> The full manual
On 01/08/19 12:02, Ulrich Mueller wrote:
> [Forwarding bug https://bugs.gentoo.org/680244 as requested by the
> Gentoo package maintainer.]
>
> According to printf(1):
>
>Interpreted sequences are:
>[...]
>
>\u Unicode (ISO/IEC 10646) character with hex value (4 digits)
[Forwarding bug https://bugs.gentoo.org/680244 as requested by the
Gentoo package maintainer.]
According to printf(1):
Interpreted sequences are:
[...]
\u Unicode (ISO/IEC 10646) character with hex value (4 digits)
\U
Unicode character with hex value