Re: [Boost-bugs] [Boost C++ Libraries] #6975: lexical_cast<double> produces different answers with 53-bit FPU precision

Subject: Re: [Boost-bugs] [Boost C++ Libraries] #6975: lexical_cast<double> produces different answers with 53-bit FPU precision
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2012-07-24 20:17:53


#6975: lexical_cast<double> produces different answers with 53-bit FPU precision
------------------------------------------------------------+---------------
  Reporter: Jonathan Jones <jonathan.jones@…> | Owner: apolukhin
      Type: Support Requests | Status: assigned
 Milestone: To Be Determined | Component: lexical_cast
   Version: Boost 1.49.0 | Severity: Cosmetic
Resolution: | Keywords:
------------------------------------------------------------+---------------

Comment (by apolukhin):

 Replying to [comment:2 Jonathan Jones <jonathan.jones@…>]:
> Replying to [comment:1 apolukhin]:
> > This issue won't be fixed in nearest future (it shall be fixed in
 ticket #5660)
>
>
> Do you have a rough estimate of the timeframe in which it will be fixed?
>
 I do not think that it would be fixed in nearest two releases of boost.

 <snip>

> FWIW, we've worked around the problem by forcing lexical_cast to always
 use:
>
> float_types_converter_internal(T& output, int /*tag*/)
>
> which doesn't seem to suffer from the same issue. It's only
 lcast_ret_float<Traits> which has the problem.

 It is good enough solution, but it may also return slightly different
 answers for some numbers on MSVC, older versions of GCC and non popular
 compilers. And this solution is slightly slower (but I do not think that
 you will notice it)

-- 
Ticket URL: <https://svn.boost.org/trac/boost/ticket/6975#comment:3>
Boost C++ Libraries <http://www.boost.org/>
Boost provides free peer-reviewed portable C++ source libraries.

This archive was generated by hypermail 2.1.7 : 2017-02-16 18:50:10 UTC