Thread overview
[phobos] phobos commit, revision 1557
May 26, 2010
dsource.org
May 26, 2010
Brad Roberts
May 26, 2010
Shin Fujishiro
May 26, 2010
phobos commit, revision 1557


user: rsinfu

msg:
We should not expect exact precision of strtold().
The precition may vary between platforms or even different versions of libc.

Tested on FreeBSD and Gentoo Linux with dmd r501.

http://www.dsource.org/projects/phobos/changeset/1557

May 25, 2010
On 5/25/2010 10:59 PM, dsource.org wrote:
> phobos commit, revision 1557
> 
> 
> user: rsinfu
> 
> msg:
> We should not expect exact precision of strtold().
> The precition may vary between platforms or even different versions of libc.
> 
> Tested on FreeBSD and Gentoo Linux with dmd r501.
> 
> http://www.dsource.org/projects/phobos/changeset/1557

I disagree with this 'fix'.  D has taken a pretty strong stance on numerical accuracy so far.  That some platform libc's have bugs means we shouldn't use those parts of those libc's and instead provide an implementation that works correctly.
May 26, 2010
Brad Roberts <braddr at puremagic.com> wrote:
> On 5/25/2010 10:59 PM, dsource.org wrote:
> > phobos commit, revision 1557
> > 
> > 
> > user: rsinfu
> > 
> > msg:
> > We should not expect exact precision of strtold().
> > The precition may vary between platforms or even different versions of libc.
> > 
> > Tested on FreeBSD and Gentoo Linux with dmd r501.
> > 
> > http://www.dsource.org/projects/phobos/changeset/1557
> 
> I disagree with this 'fix'.  D has taken a pretty strong stance on numerical accuracy so far.  That some platform libc's have bugs means we shouldn't use those parts of those libc's and instead provide an implementation that works correctly.

That makes a lot of sense. I see; strict unittests are requirements for D, and those unittests should fail on these platforms.

I'll revert the change later. (dsource.org is down now)


Shin