Use boost::declval instead of std::declval, close #10190.

Thanks-to: Niklas Angare
This commit is contained in:
Niklas Angare
2014-07-11 14:26:14 -04:00
committed by Kohei Takahashi
parent 6b6d613e15
commit 3b3da1a10a
5 changed files with 16 additions and 11 deletions

View File

@ -9,6 +9,7 @@
#include <boost/fusion/support/config.hpp>
#include <boost/fusion/support/detail/access.hpp>
#include <boost/utility/declval.hpp>
namespace boost { namespace fusion
{
@ -27,7 +28,7 @@ namespace boost { namespace fusion
{
typedef mpl::int_<N::value> index;
typedef
decltype(std::declval<Sequence>().get(index()))
decltype(boost::declval<Sequence>().get(index()))
type;
BOOST_FUSION_GPU_ENABLED
@ -43,7 +44,7 @@ namespace boost { namespace fusion
{
typedef mpl::int_<N::value> index;
typedef
decltype(std::declval<Sequence const>().get(index()))
decltype(boost::declval<Sequence const>().get(index()))
type;
BOOST_FUSION_GPU_ENABLED

View File

@ -12,6 +12,7 @@
#include <boost/type_traits/is_const.hpp>
#include <boost/mpl/at.hpp>
#include <boost/mpl/identity.hpp>
#include <boost/utility/declval.hpp>
namespace boost { namespace fusion
{
@ -29,7 +30,7 @@ namespace boost { namespace fusion
struct apply
{
typedef
decltype(std::declval<Sequence>().get(mpl::identity<Key>()))
decltype(boost::declval<Sequence>().get(mpl::identity<Key>()))
type;
BOOST_FUSION_GPU_ENABLED
@ -44,7 +45,7 @@ namespace boost { namespace fusion
struct apply<Sequence const, Key>
{
typedef
decltype(std::declval<Sequence const>().get(mpl::identity<Key>()))
decltype(boost::declval<Sequence const>().get(mpl::identity<Key>()))
type;
BOOST_FUSION_GPU_ENABLED

View File

@ -9,6 +9,7 @@
#include <boost/fusion/support/config.hpp>
#include <boost/mpl/at.hpp>
#include <boost/utility/declval.hpp>
namespace boost { namespace fusion
{
@ -27,7 +28,7 @@ namespace boost { namespace fusion
{
typedef mpl::int_<N::value> index;
typedef
decltype(std::declval<Sequence>().get_val(index()))
decltype(boost::declval<Sequence>().get_val(index()))
type;
};
};

View File

@ -12,6 +12,7 @@
#include <boost/type_traits/is_const.hpp>
#include <boost/mpl/at.hpp>
#include <boost/mpl/identity.hpp>
#include <boost/utility/declval.hpp>
namespace boost { namespace fusion
{
@ -29,7 +30,7 @@ namespace boost { namespace fusion
struct apply
{
typedef
decltype(std::declval<Sequence>().get_val(mpl::identity<Key>()))
decltype(boost::declval<Sequence>().get_val(mpl::identity<Key>()))
type;
};
};