GNU bug report logs - #54785
for floating point, printf should use double like in C instead of long double

Previous Next

Package: coreutils;

Reported by: Vincent Lefevre <vincent <at> vinc17.net>

Date: Fri, 8 Apr 2022 09:18:01 UTC

Severity: normal

Full log


Message #32 received at 54785 <at> debbugs.gnu.org (full text, mbox):

From: "Glenn Golden" <gdg <at> zplane.com>
To: "Paul Eggert" <eggert <at> cs.ucla.edu>, 54785 <at> debbugs.gnu.org
Subject: Re: bug#54785: for floating point,
 printf should use double like in C instead of long double
Date: Wed, 27 Apr 2022 06:10:21 -0600

On Mon, Apr 25, 2022, at 19:33, Paul Eggert wrote:
> On 4/25/22 16:50, Glenn Golden wrote:
>> 
>> 
>> On Mon, Apr 25, 2022, at 13:06, Paul Eggert wrote:
>>>
>>> I'd like coreutils printf to stay compatible with Bash printf. Thanks.
>>>
>> 
>> Is there any interest/motivation for consistentizing {coreutils printf, bash printf} with glibc printf? There's a minor but notable inconsistency between them for %a format. See
>> 
>>      https://lists.gnu.org/archive/html/coreutils/2022-04/msg00020.html
>> 
>> I asked about this on the coreutils list, but no response.
>
> To some extent it's the same problem. If Bash and coreutils printf 
> change to use 'double', they'll output the same thing that C printf outputs.
>
> But to some extent it's a different problem, as the Bash and coreutils 
> printf use glibc printf with long double, and the latter isn't working 
> consistently with double. I suppose filing a glibc bug report might 
> address this different problem.
>

Ok, I see what you mean, thanks for the explanation. I'll pose the question (or maybe file a bug report) on the glibc list.

Thanks,
Glenn




This bug report was last modified 3 years and 46 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.