Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 12 Apr 2002 22:08:26 -0600 (MDT)
From:      "M. Warner Losh" <imp@village.org>
To:        tim@robbins.dropbear.id.au
Cc:        freebsd-standards@FreeBSD.ORG
Subject:   Re: standards/36783
Message-ID:  <20020412.220826.123419371.imp@village.org>
In-Reply-To: <20020413135358.A9710@treetop.robbins.dropbear.id.au>
References:  <200204121639.g3CGdOZ90234@khavrinen.lcs.mit.edu> <20020412.121645.03985114.imp@village.org> <20020413135358.A9710@treetop.robbins.dropbear.id.au>

next in thread | previous in thread | raw e-mail | index | archive | help
In message: <20020413135358.A9710@treetop.robbins.dropbear.id.au>
            "Tim J. Robbins" <tim@robbins.dropbear.id.au> writes:
: On Fri, Apr 12, 2002 at 12:16:45PM -0600, M. Warner Losh wrote:
: 
: > This is no longer true.  Long doubles can and do give better precision
: > than doubles, but at a high performance cost.  printf can't print a
: > long double more precisely than what double can represent, however,
: > since printf casts it to a double first.
: 
: This sounds like something that needs to get documented in printf(3), then
: eventually fixed (I can't think of an elegant way to fix it right now).

A co-worker has fixes in his tree, but he's not happy enough with them
yet to have me commit them.  He got them from NetBSD.

: What I'll do is leave the format string the same as for a double, and
: make a note explaining that it was working around a printf limitation.
: Thanks for the info.

I don't understand this.  You print doubles with %f and long doubles
with %Lf.

Warner

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-standards" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20020412.220826.123419371.imp>