[Boost-bugs] [Boost C++ Libraries] #8941: Detection of availability of 128-bit integers should be left on Boost.Config

Subject: [Boost-bugs] [Boost C++ Libraries] #8941: Detection of availability of 128-bit integers should be left on Boost.Config
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2013-07-30 17:45:36


#8941: Detection of availability of 128-bit integers should be left on
Boost.Config
---------------------------------------+--------------------------
 Reporter: Petr Machata <pmachata@…> | Owner: apolukhin
     Type: Bugs | Status: new
Milestone: To Be Determined | Component: lexical_cast
  Version: Boost 1.54.0 | Severity: Problem
 Keywords: |
---------------------------------------+--------------------------
 The following code in lexical_cast.hpp appears wrong:

 {{{
 #if (defined(BOOST_LCAST_HAS_INT128) && !defined(__GNUC__)) || GCC_VERSION
> 40700
 #define BOOST_LCAST_HAS_INT128
 #endif
 }}}

 I'm uncertain whether BOOST_LCAST_HAS_INT128 serves some purpose such as
 per-library configuration. It seems to me it would be best to simply
 defer this logic to config.hpp, drop this piece of code, and later on
 dispatch on BOOST_HAS_INT128. I'm attaching a patch to this effect.

 Note that this logic currently breaks on i386, where GCC doesn't support
 128-bit data types even though it otherwise satisfies the above condition.

 If you wish to have this configured specifically for lexical cast, I can
 work in some logic that overrides BOOST_HAS_INT128 in favor of whatever
 BOOST_LCAST_HAS_INT128 setting came from the "outside" (if any).

-- 
Ticket URL: <https://svn.boost.org/trac/boost/ticket/8941>
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:13 UTC