From 8286ac511144e4f17d34eac9affb97e50646344a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Frings-F=C3=BCrst?= Date: Wed, 23 Jul 2014 15:25:44 +0200 Subject: Imported Upstream version 4.0.0 --- .../cutl/details/boost/type_traits/is_integral.hpp | 83 ++++++++++++++++++++++ 1 file changed, 83 insertions(+) create mode 100644 libcutl/cutl/details/boost/type_traits/is_integral.hpp (limited to 'libcutl/cutl/details/boost/type_traits/is_integral.hpp') diff --git a/libcutl/cutl/details/boost/type_traits/is_integral.hpp b/libcutl/cutl/details/boost/type_traits/is_integral.hpp new file mode 100644 index 0000000..f5203bb --- /dev/null +++ b/libcutl/cutl/details/boost/type_traits/is_integral.hpp @@ -0,0 +1,83 @@ + +// (C) Copyright Steve Cleary, Beman Dawes, Howard Hinnant & John Maddock 2000. +// Use, modification and distribution are subject to the Boost Software License, +// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt). +// +// See http://www.boost.org/libs/type_traits for most recent version including documentation. + +#ifndef BOOST_TT_IS_INTEGRAL_HPP_INCLUDED +#define BOOST_TT_IS_INTEGRAL_HPP_INCLUDED + +#include + +// should be the last #include +#include + +namespace cutl_details_boost { + +//* is a type T an [cv-qualified-] integral type described in the standard (3.9.1p3) +// as an extension we include long long, as this is likely to be added to the +// standard at a later date +#if defined( __CODEGEARC__ ) +BOOST_TT_AUX_BOOL_TRAIT_DEF1(is_integral,T,__is_integral(T)) +#else +BOOST_TT_AUX_BOOL_TRAIT_DEF1(is_integral,T,false) + +BOOST_TT_AUX_BOOL_TRAIT_CV_SPEC1(is_integral,unsigned char,true) +BOOST_TT_AUX_BOOL_TRAIT_CV_SPEC1(is_integral,unsigned short,true) +BOOST_TT_AUX_BOOL_TRAIT_CV_SPEC1(is_integral,unsigned int,true) +BOOST_TT_AUX_BOOL_TRAIT_CV_SPEC1(is_integral,unsigned long,true) + +BOOST_TT_AUX_BOOL_TRAIT_CV_SPEC1(is_integral,signed char,true) +BOOST_TT_AUX_BOOL_TRAIT_CV_SPEC1(is_integral,signed short,true) +BOOST_TT_AUX_BOOL_TRAIT_CV_SPEC1(is_integral,signed int,true) +BOOST_TT_AUX_BOOL_TRAIT_CV_SPEC1(is_integral,signed long,true) + +BOOST_TT_AUX_BOOL_TRAIT_CV_SPEC1(is_integral,bool,true) +BOOST_TT_AUX_BOOL_TRAIT_CV_SPEC1(is_integral,char,true) + +#ifndef BOOST_NO_INTRINSIC_WCHAR_T +// If the following line fails to compile and you're using the Intel +// compiler, see http://lists.boost.org/MailArchives/boost-users/msg06567.php, +// and define BOOST_NO_INTRINSIC_WCHAR_T on the command line. +BOOST_TT_AUX_BOOL_TRAIT_CV_SPEC1(is_integral,wchar_t,true) +#endif + +// Same set of integral types as in boost/type_traits/integral_promotion.hpp. +// Please, keep in sync. -- Alexander Nasonov +#if (defined(BOOST_MSVC) && (BOOST_MSVC < 1300)) \ + || (defined(BOOST_INTEL_CXX_VERSION) && defined(_MSC_VER) && (BOOST_INTEL_CXX_VERSION <= 600)) \ + || (defined(__BORLANDC__) && (__BORLANDC__ == 0x600) && (_MSC_VER < 1300)) +BOOST_TT_AUX_BOOL_TRAIT_CV_SPEC1(is_integral,unsigned __int8,true) +BOOST_TT_AUX_BOOL_TRAIT_CV_SPEC1(is_integral,__int8,true) +BOOST_TT_AUX_BOOL_TRAIT_CV_SPEC1(is_integral,unsigned __int16,true) +BOOST_TT_AUX_BOOL_TRAIT_CV_SPEC1(is_integral,__int16,true) +BOOST_TT_AUX_BOOL_TRAIT_CV_SPEC1(is_integral,unsigned __int32,true) +BOOST_TT_AUX_BOOL_TRAIT_CV_SPEC1(is_integral,__int32,true) +#ifdef __BORLANDC__ +BOOST_TT_AUX_BOOL_TRAIT_CV_SPEC1(is_integral,unsigned __int64,true) +BOOST_TT_AUX_BOOL_TRAIT_CV_SPEC1(is_integral,__int64,true) +#endif +#endif + +# if defined(BOOST_HAS_LONG_LONG) +BOOST_TT_AUX_BOOL_TRAIT_CV_SPEC1(is_integral, ::cutl_details_boost::ulong_long_type,true) +BOOST_TT_AUX_BOOL_TRAIT_CV_SPEC1(is_integral, ::cutl_details_boost::long_long_type,true) +#elif defined(BOOST_HAS_MS_INT64) +BOOST_TT_AUX_BOOL_TRAIT_CV_SPEC1(is_integral,unsigned __int64,true) +BOOST_TT_AUX_BOOL_TRAIT_CV_SPEC1(is_integral,__int64,true) +#endif + +#ifdef BOOST_HAS_INT128 +BOOST_TT_AUX_BOOL_TRAIT_CV_SPEC1(is_integral,cutl_details_boost::int128_type,true) +BOOST_TT_AUX_BOOL_TRAIT_CV_SPEC1(is_integral,cutl_details_boost::uint128_type,true) +#endif + +#endif // non-CodeGear implementation + +} // namespace cutl_details_boost + +#include + +#endif // BOOST_TT_IS_INTEGRAL_HPP_INCLUDED -- cgit v1.2.3