williamr@2
|
1 |
|
williamr@2
|
2 |
#ifndef BOOST_MPL_SET_AUX_HAS_KEY_IMPL_HPP_INCLUDED
|
williamr@2
|
3 |
#define BOOST_MPL_SET_AUX_HAS_KEY_IMPL_HPP_INCLUDED
|
williamr@2
|
4 |
|
williamr@2
|
5 |
// Copyright Aleksey Gurtovoy 2003-2004
|
williamr@2
|
6 |
// Copyright David Abrahams 2003-2004
|
williamr@2
|
7 |
//
|
williamr@2
|
8 |
// Distributed under the Boost Software License, Version 1.0.
|
williamr@2
|
9 |
// (See accompanying file LICENSE_1_0.txt or copy at
|
williamr@2
|
10 |
// http://www.boost.org/LICENSE_1_0.txt)
|
williamr@2
|
11 |
//
|
williamr@2
|
12 |
// See http://www.boost.org/libs/mpl for documentation.
|
williamr@2
|
13 |
|
williamr@2
|
14 |
// $Source: /cvsroot/boost/boost/boost/mpl/set/aux_/has_key_impl.hpp,v $
|
williamr@2
|
15 |
// $Date: 2004/10/13 18:23:37 $
|
williamr@2
|
16 |
// $Revision: 1.7 $
|
williamr@2
|
17 |
|
williamr@2
|
18 |
#include <boost/mpl/set/aux_/tag.hpp>
|
williamr@2
|
19 |
#include <boost/mpl/has_key_fwd.hpp>
|
williamr@2
|
20 |
#include <boost/mpl/bool.hpp>
|
williamr@2
|
21 |
#include <boost/mpl/aux_/overload_names.hpp>
|
williamr@2
|
22 |
#include <boost/mpl/aux_/static_cast.hpp>
|
williamr@2
|
23 |
#include <boost/mpl/aux_/yes_no.hpp>
|
williamr@2
|
24 |
#include <boost/mpl/aux_/type_wrapper.hpp>
|
williamr@2
|
25 |
#include <boost/mpl/aux_/config/workaround.hpp>
|
williamr@2
|
26 |
#include <boost/mpl/aux_/config/static_constant.hpp>
|
williamr@2
|
27 |
|
williamr@2
|
28 |
namespace boost { namespace mpl {
|
williamr@2
|
29 |
|
williamr@2
|
30 |
template<>
|
williamr@2
|
31 |
struct has_key_impl< aux::set_tag >
|
williamr@2
|
32 |
{
|
williamr@2
|
33 |
template< typename Set, typename T > struct apply
|
williamr@2
|
34 |
#if BOOST_WORKAROUND(BOOST_MSVC, BOOST_TESTED_AT(1400)) \
|
williamr@2
|
35 |
|| BOOST_WORKAROUND(__EDG_VERSION__, <= 245)
|
williamr@2
|
36 |
{
|
williamr@2
|
37 |
BOOST_STATIC_CONSTANT(bool, value =
|
williamr@2
|
38 |
( sizeof( BOOST_MPL_AUX_OVERLOAD_CALL_IS_MASKED(
|
williamr@2
|
39 |
Set
|
williamr@2
|
40 |
, BOOST_MPL_AUX_STATIC_CAST(aux::type_wrapper<T>*, 0)
|
williamr@2
|
41 |
) ) == sizeof(aux::no_tag) )
|
williamr@2
|
42 |
);
|
williamr@2
|
43 |
|
williamr@2
|
44 |
typedef bool_<value> type;
|
williamr@2
|
45 |
|
williamr@2
|
46 |
#else // ISO98 C++
|
williamr@2
|
47 |
: bool_<
|
williamr@2
|
48 |
( sizeof( BOOST_MPL_AUX_OVERLOAD_CALL_IS_MASKED(
|
williamr@2
|
49 |
Set
|
williamr@2
|
50 |
, BOOST_MPL_AUX_STATIC_CAST(aux::type_wrapper<T>*, 0)
|
williamr@2
|
51 |
) ) == sizeof(aux::no_tag) )
|
williamr@2
|
52 |
>
|
williamr@2
|
53 |
{
|
williamr@2
|
54 |
#endif
|
williamr@2
|
55 |
};
|
williamr@2
|
56 |
};
|
williamr@2
|
57 |
|
williamr@2
|
58 |
}}
|
williamr@2
|
59 |
|
williamr@2
|
60 |
#endif // BOOST_MPL_SET_AUX_HAS_KEY_IMPL_HPP_INCLUDED
|