Subject: [Boost-bugs] [Boost C++ Libraries] #3084: integer_traits for std::streamsize not defined for Visual C++ in 64-bit when language extensions are off
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2009-05-26 03:07:03
#3084: integer_traits for std::streamsize not defined for Visual C++ in 64-bit
when language extensions are off
----------------------------------+-----------------------------------------
Reporter: boost_at_[hidden] | Owner: az_sw_dude
Type: Bugs | Status: new
Milestone: Boost 1.40.0 | Component: date_time
Version: Boost 1.39.0 | Severity: Showstopper
Keywords: |
----------------------------------+-----------------------------------------
The following does not compile if you disable language extensions and
build in 64-bit:
{{{
#include <boost/integer_traits.hpp>
#include <iostream>
int main()
{
boost::integer_traits<std::streamsize>::const_max;
}
}}}
This makes it impossible to use boost date_time in 64-bit.
The fix is below (add to integer_traits.hpp):
{{{
#if defined(BOOST_HAS_MS_INT64) && !defined(_MSC_EXTENSIONS)
template<>
class integer_traits< __int64 >
: public std::numeric_limits< __int64 >,
public detail::integer_traits_base< __int64, _I64_MIN ,
_I64_MAX>
{ };
#endif
}}}
-- Ticket URL: <https://svn.boost.org/trac/boost/ticket/3084> 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:00 UTC