Merged changes from RC_1_29_0 branch

[SVN r15958]
This commit is contained in:
John Maddock
2002-10-21 11:00:50 +00:00
parent 2de1422682
commit 9cc587a7f2
2 changed files with 30 additions and 8 deletions

View File

@ -35,7 +35,7 @@
// this is triggered with GCC, because it defines __cplusplus < 199707L // this is triggered with GCC, because it defines __cplusplus < 199707L
# define BOOST_NO_INT64_T # define BOOST_NO_INT64_T
# endif # endif
# elif defined(__FreeBSD__) # elif defined(__FreeBSD__) || defined(__IBMCPP__)
# include <inttypes.h> # include <inttypes.h>
# else # else
# include <stdint.h> # include <stdint.h>

View File

@ -147,42 +147,64 @@ class integer_traits<unsigned long>
public detail::integer_traits_base<unsigned long, 0, ULONG_MAX> public detail::integer_traits_base<unsigned long, 0, ULONG_MAX>
{ }; { };
#if defined(ULLONG_MAX) && !defined(__SUNPRO_CC) #if !defined(BOOST_NO_INTEGRAL_INT64_T) && !defined(BOOST_NO_INT64_T)
#if defined(ULLONG_MAX) && defined(BOOST_HAS_LONG_LONG)
template<> template<>
class integer_traits<long long> class integer_traits<long long>
: public std::numeric_limits<long long>, : public std::numeric_limits<long long>,
public detail::integer_traits_base<long long, LLONG_MIN, LLONG_MAX> public detail::integer_traits_base<long long, LLONG_MIN, LLONG_MAX>
{ }; { };
template<> template<>
class integer_traits<unsigned long long> class integer_traits<unsigned long long>
: public std::numeric_limits<unsigned long long>, : public std::numeric_limits<unsigned long long>,
public detail::integer_traits_base<unsigned long long, 0, ULLONG_MAX> public detail::integer_traits_base<unsigned long long, 0, ULLONG_MAX>
{ }; { };
#elif defined(ULONG_LONG_MAX)
#elif defined(ULONG_LONG_MAX) && defined(BOOST_HAS_LONG_LONG)
template<> template<>
class integer_traits<long long> class integer_traits<long long> : public std::numeric_limits<long long>, public detail::integer_traits_base<long long, LONG_LONG_MIN, LONG_LONG_MAX>{ };
: public std::numeric_limits<long long>,
public detail::integer_traits_base<long long, LONG_LONG_MIN, LONG_LONG_MAX>
{ };
template<> template<>
class integer_traits<unsigned long long> class integer_traits<unsigned long long>
: public std::numeric_limits<unsigned long long>, : public std::numeric_limits<unsigned long long>,
public detail::integer_traits_base<unsigned long long, 0, ULONG_LONG_MAX> public detail::integer_traits_base<unsigned long long, 0, ULONG_LONG_MAX>
{ }; { };
#elif defined(ULONGLONG_MAX) && !defined(BOOST_MSVC) && !defined(__BORLANDC__)
#elif defined(ULONGLONG_MAX) && defined(BOOST_HAS_LONG_LONG)
template<> template<>
class integer_traits<long long> class integer_traits<long long>
: public std::numeric_limits<long long>, : public std::numeric_limits<long long>,
public detail::integer_traits_base<long long, LONGLONG_MIN, LONGLONG_MAX> public detail::integer_traits_base<long long, LONGLONG_MIN, LONGLONG_MAX>
{ }; { };
template<> template<>
class integer_traits<unsigned long long> class integer_traits<unsigned long long>
: public std::numeric_limits<unsigned long long>, : public std::numeric_limits<unsigned long long>,
public detail::integer_traits_base<unsigned long long, 0, ULONGLONG_MAX> public detail::integer_traits_base<unsigned long long, 0, ULONGLONG_MAX>
{ }; { };
#elif defined(_LLONG_MAX) && defined(_C2) && defined(BOOST_HAS_LONG_LONG)
template<>
class integer_traits<long long>
: public std::numeric_limits<long long>,
public detail::integer_traits_base<long long, -_LLONG_MAX - _C2, _LLONG_MAX>
{ };
template<>
class integer_traits<unsigned long long>
: public std::numeric_limits<unsigned long long>,
public detail::integer_traits_base<unsigned long long, 0, _ULLONG_MAX>
{ };
#endif
#endif #endif
} // namespace boost } // namespace boost
#endif /* BOOST_INTEGER_TRAITS_HPP */ #endif /* BOOST_INTEGER_TRAITS_HPP */