Chris@102: /* Copyright 2003-2014 Joaquin M Lopez Munoz. Chris@102: * Distributed under the Boost Software License, Version 1.0. Chris@102: * (See accompanying file LICENSE_1_0.txt or copy at Chris@102: * http://www.boost.org/LICENSE_1_0.txt) Chris@102: * Chris@102: * See http://www.boost.org/libs/multi_index for library home page. Chris@102: */ Chris@102: Chris@102: #ifndef BOOST_MULTI_INDEX_DETAIL_PROMOTES_ARG_HPP Chris@102: #define BOOST_MULTI_INDEX_DETAIL_PROMOTES_ARG_HPP Chris@102: Chris@102: #if defined(_MSC_VER) Chris@102: #pragma once Chris@102: #endif Chris@102: Chris@102: #include /* keep it first to prevent nasty warns in MSVC */ Chris@102: #include Chris@102: #include Chris@102: Chris@102: /* Metafunctions to check if f(arg1,arg2) promotes either arg1 to the type of Chris@102: * arg2 or viceversa. By default, (i.e. if it cannot be determined), no Chris@102: * promotion is assumed. Chris@102: */ Chris@102: Chris@102: #if !defined(BOOST_IS_CONVERTIBLE) Chris@102: Chris@102: namespace boost{ Chris@102: Chris@102: namespace multi_index{ Chris@102: Chris@102: namespace detail{ Chris@102: Chris@102: template Chris@102: struct promotes_1st_arg:mpl::false_{}; Chris@102: Chris@102: template Chris@102: struct promotes_2nd_arg:mpl::false_{}; Chris@102: Chris@102: } /* namespace multi_index::detail */ Chris@102: Chris@102: } /* namespace multi_index */ Chris@102: Chris@102: } /* namespace boost */ Chris@102: Chris@102: #else Chris@102: Chris@102: #include Chris@102: #include Chris@102: #include Chris@102: #include Chris@102: Chris@102: namespace boost{ Chris@102: Chris@102: namespace multi_index{ Chris@102: Chris@102: namespace detail{ Chris@102: Chris@102: template Chris@102: struct promotes_1st_arg: Chris@102: mpl::and_< Chris@102: mpl::not_ >, Chris@102: is_convertible, Chris@102: is_transparent Chris@102: > Chris@102: {}; Chris@102: Chris@102: template Chris@102: struct promotes_2nd_arg: Chris@102: mpl::and_< Chris@102: mpl::not_ >, Chris@102: is_convertible, Chris@102: is_transparent Chris@102: > Chris@102: {}; Chris@102: Chris@102: } /* namespace multi_index::detail */ Chris@102: Chris@102: } /* namespace multi_index */ Chris@102: Chris@102: } /* namespace boost */ Chris@102: Chris@102: #endif /* defined(BOOST_IS_CONVERTIBLE) */ Chris@102: #endif