2
#ifndef BOOST_MPL_AUX_HAS_REBIND_HPP_INCLUDED
3
#define BOOST_MPL_AUX_HAS_REBIND_HPP_INCLUDED
5
// Copyright Aleksey Gurtovoy 2002-2004
7
// Distributed under the Boost Software License, Version 1.0.
8
// (See accompanying file LICENSE_1_0.txt or copy at
9
// http://www.boost.org/LICENSE_1_0.txt)
11
// See http://www.boost.org/libs/mpl for documentation.
13
// $Id: has_rebind.hpp 49267 2008-10-11 06:19:02Z agurtovoy $
14
// $Date: 2008-10-10 23:19:02 -0700 (Fri, 10 Oct 2008) $
17
#include <boost/mpl/aux_/config/msvc.hpp>
18
#include <boost/mpl/aux_/config/intel.hpp>
19
#include <boost/mpl/aux_/config/workaround.hpp>
21
#if BOOST_WORKAROUND(__EDG_VERSION__, <= 244) && !defined(BOOST_INTEL_CXX_VERSION)
22
# include <boost/mpl/has_xxx.hpp>
23
#elif BOOST_WORKAROUND(BOOST_MSVC, < 1300)
24
# include <boost/mpl/has_xxx.hpp>
25
# include <boost/mpl/if.hpp>
26
# include <boost/mpl/bool.hpp>
27
# include <boost/mpl/aux_/msvc_is_class.hpp>
28
#elif BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x610))
29
# include <boost/mpl/if.hpp>
30
# include <boost/mpl/bool.hpp>
31
# include <boost/mpl/aux_/yes_no.hpp>
32
# include <boost/mpl/aux_/config/static_constant.hpp>
33
# include <boost/type_traits/is_class.hpp>
35
# include <boost/mpl/aux_/type_wrapper.hpp>
36
# include <boost/mpl/aux_/yes_no.hpp>
37
# include <boost/mpl/aux_/config/static_constant.hpp>
40
namespace boost { namespace mpl { namespace aux {
42
#if BOOST_WORKAROUND(__EDG_VERSION__, <= 244) && !defined(BOOST_INTEL_CXX_VERSION)
44
BOOST_MPL_HAS_XXX_TRAIT_NAMED_DEF(has_rebind, rebind, false)
46
#elif BOOST_WORKAROUND(BOOST_MSVC, < 1300)
48
BOOST_MPL_HAS_XXX_TRAIT_NAMED_DEF(has_rebind_impl, rebind, false)
50
template< typename T >
62
template< typename T > struct has_rebind_tag {};
63
no_tag operator|(has_rebind_tag<int>, void const volatile*);
65
# if !BOOST_WORKAROUND(__BORLANDC__, BOOST_TESTED_AT(0x610))
66
template< typename T >
69
static has_rebind_tag<T>* get();
70
BOOST_STATIC_CONSTANT(bool, value =
71
sizeof(has_rebind_tag<int>() | get()) == sizeof(yes_tag)
74
# else // __BORLANDC__
75
template< typename T >
76
struct has_rebind_impl
79
BOOST_STATIC_CONSTANT(bool, value =
80
sizeof(has_rebind_tag<int>() | get()) == sizeof(yes_tag)
84
template< typename T >
93
# endif // __BORLANDC__
99
#endif // BOOST_MPL_AUX_HAS_REBIND_HPP_INCLUDED