summaryrefslogtreecommitdiff
path: root/boost/fusion/view/nview
diff options
context:
space:
mode:
authorDongHun Kwak <dh0128.kwak@samsung.com>2016-03-21 15:45:20 +0900
committerDongHun Kwak <dh0128.kwak@samsung.com>2016-03-21 15:46:37 +0900
commit733b5d5ae2c5d625211e2985ac25728ac3f54883 (patch)
treea5b214744b256f07e1dc2bd7273035a7808c659f /boost/fusion/view/nview
parent08c1e93fa36a49f49325a07fe91ff92c964c2b6c (diff)
downloadboost-733b5d5ae2c5d625211e2985ac25728ac3f54883.tar.gz
boost-733b5d5ae2c5d625211e2985ac25728ac3f54883.tar.bz2
boost-733b5d5ae2c5d625211e2985ac25728ac3f54883.zip
Imported Upstream version 1.58.0upstream/1.58.0
Change-Id: If0072143aa26874812e0db6872e1efb10a3e5e94 Signed-off-by: DongHun Kwak <dh0128.kwak@samsung.com>
Diffstat (limited to 'boost/fusion/view/nview')
-rw-r--r--boost/fusion/view/nview/detail/advance_impl.hpp4
-rw-r--r--boost/fusion/view/nview/detail/at_impl.hpp6
-rw-r--r--boost/fusion/view/nview/detail/begin_impl.hpp2
-rw-r--r--boost/fusion/view/nview/detail/deref_impl.hpp2
-rw-r--r--boost/fusion/view/nview/detail/distance_impl.hpp2
-rw-r--r--boost/fusion/view/nview/detail/end_impl.hpp2
-rw-r--r--boost/fusion/view/nview/detail/next_impl.hpp2
-rw-r--r--boost/fusion/view/nview/detail/nview_impl.hpp2
-rw-r--r--boost/fusion/view/nview/detail/prior_impl.hpp2
-rw-r--r--boost/fusion/view/nview/nview.hpp11
-rw-r--r--boost/fusion/view/nview/nview_iterator.hpp12
11 files changed, 29 insertions, 18 deletions
diff --git a/boost/fusion/view/nview/detail/advance_impl.hpp b/boost/fusion/view/nview/detail/advance_impl.hpp
index ad82983eac..7c74a386bb 100644
--- a/boost/fusion/view/nview/detail/advance_impl.hpp
+++ b/boost/fusion/view/nview/detail/advance_impl.hpp
@@ -12,7 +12,7 @@
#include <boost/mpl/advance.hpp>
#include <boost/fusion/iterator/advance.hpp>
-namespace boost { namespace fusion
+namespace boost { namespace fusion
{
struct nview_iterator_tag;
@@ -36,7 +36,7 @@ namespace boost { namespace fusion
typedef nview_iterator<sequence_type,
typename mpl::advance<iterator_type, Dist>::type> type;
- BOOST_FUSION_GPU_ENABLED
+ BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED
static type
call(Iterator const& i)
{
diff --git a/boost/fusion/view/nview/detail/at_impl.hpp b/boost/fusion/view/nview/detail/at_impl.hpp
index 45f9faf6f6..b9f41defcd 100644
--- a/boost/fusion/view/nview/detail/at_impl.hpp
+++ b/boost/fusion/view/nview/detail/at_impl.hpp
@@ -11,7 +11,7 @@
#include <boost/fusion/support/config.hpp>
#include <boost/fusion/sequence/intrinsic/at.hpp>
-namespace boost { namespace fusion
+namespace boost { namespace fusion
{
struct nview_tag;
@@ -32,8 +32,8 @@ namespace boost { namespace fusion
typedef typename result_of::at<index_type, N>::type index;
typedef typename result_of::at<sequence_type, index>::type type;
- BOOST_FUSION_GPU_ENABLED
- static type
+ BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED
+ static type
call(Sequence& seq)
{
return fusion::at<index>(seq.seq);
diff --git a/boost/fusion/view/nview/detail/begin_impl.hpp b/boost/fusion/view/nview/detail/begin_impl.hpp
index ca600b9a16..bab5e221c9 100644
--- a/boost/fusion/view/nview/detail/begin_impl.hpp
+++ b/boost/fusion/view/nview/detail/begin_impl.hpp
@@ -35,7 +35,7 @@ namespace boost { namespace fusion
typedef nview_iterator<Sequence,
typename mpl::begin<index_type>::type> type;
- BOOST_FUSION_GPU_ENABLED
+ BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED
static type call(Sequence& s)
{
return type(s);
diff --git a/boost/fusion/view/nview/detail/deref_impl.hpp b/boost/fusion/view/nview/detail/deref_impl.hpp
index bbdb982528..85991021b6 100644
--- a/boost/fusion/view/nview/detail/deref_impl.hpp
+++ b/boost/fusion/view/nview/detail/deref_impl.hpp
@@ -34,7 +34,7 @@ namespace boost { namespace fusion
typedef typename result_of::at<
typename sequence_type::sequence_type, index>::type type;
- BOOST_FUSION_GPU_ENABLED
+ BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED
static type call(Iterator const& i)
{
return at<index>(i.seq.seq);
diff --git a/boost/fusion/view/nview/detail/distance_impl.hpp b/boost/fusion/view/nview/detail/distance_impl.hpp
index e3e5a9a086..a036300f77 100644
--- a/boost/fusion/view/nview/detail/distance_impl.hpp
+++ b/boost/fusion/view/nview/detail/distance_impl.hpp
@@ -31,7 +31,7 @@ namespace boost { namespace fusion
typename First::first_type, typename Last::first_type
>::type type;
- BOOST_FUSION_GPU_ENABLED
+ BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED
static type
call(First const& /*first*/, Last const& /*last*/)
{
diff --git a/boost/fusion/view/nview/detail/end_impl.hpp b/boost/fusion/view/nview/detail/end_impl.hpp
index d36260dbb7..0a6efe560d 100644
--- a/boost/fusion/view/nview/detail/end_impl.hpp
+++ b/boost/fusion/view/nview/detail/end_impl.hpp
@@ -36,7 +36,7 @@ namespace boost { namespace fusion
typedef nview_iterator<Sequence,
typename mpl::end<index_type>::type> type;
- BOOST_FUSION_GPU_ENABLED
+ BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED
static type call(Sequence& s)
{
return type(s);
diff --git a/boost/fusion/view/nview/detail/next_impl.hpp b/boost/fusion/view/nview/detail/next_impl.hpp
index 5193bfe655..3c30409647 100644
--- a/boost/fusion/view/nview/detail/next_impl.hpp
+++ b/boost/fusion/view/nview/detail/next_impl.hpp
@@ -35,7 +35,7 @@ namespace boost { namespace fusion
typedef nview_iterator<sequence_type,
typename mpl::next<first_type>::type> type;
- BOOST_FUSION_GPU_ENABLED
+ BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED
static type
call(Iterator const& i)
{
diff --git a/boost/fusion/view/nview/detail/nview_impl.hpp b/boost/fusion/view/nview/detail/nview_impl.hpp
index 6c7a3e21d1..e0d9335638 100644
--- a/boost/fusion/view/nview/detail/nview_impl.hpp
+++ b/boost/fusion/view/nview/detail/nview_impl.hpp
@@ -63,7 +63,7 @@ namespace boost { namespace fusion { namespace result_of
namespace boost { namespace fusion
{
template<BOOST_PP_ENUM_PARAMS(N, int I), typename Sequence>
- BOOST_FUSION_GPU_ENABLED
+ BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED
inline nview<Sequence, mpl::vector_c<int, BOOST_PP_ENUM_PARAMS(N, I)> >
as_nview(Sequence& s)
{
diff --git a/boost/fusion/view/nview/detail/prior_impl.hpp b/boost/fusion/view/nview/detail/prior_impl.hpp
index 374b45f669..470c5bd323 100644
--- a/boost/fusion/view/nview/detail/prior_impl.hpp
+++ b/boost/fusion/view/nview/detail/prior_impl.hpp
@@ -35,7 +35,7 @@ namespace boost { namespace fusion
typedef nview_iterator<sequence_type,
typename mpl::prior<first_type>::type> type;
- BOOST_FUSION_GPU_ENABLED
+ BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED
static type
call(Iterator const& i)
{
diff --git a/boost/fusion/view/nview/nview.hpp b/boost/fusion/view/nview/nview.hpp
index 45b7380bdf..2e257c81de 100644
--- a/boost/fusion/view/nview/nview.hpp
+++ b/boost/fusion/view/nview/nview.hpp
@@ -40,7 +40,7 @@ namespace boost { namespace fusion
#ifdef BOOST_NO_CXX11_RVALUE_REFERENCES
template <typename T>
- BOOST_FUSION_GPU_ENABLED
+ BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED
typename add_reference<T>::type
operator()(T& x) const
{
@@ -48,7 +48,7 @@ namespace boost { namespace fusion
}
#else
template <typename T>
- BOOST_FUSION_GPU_ENABLED
+ BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED
typename result<addref(T)>::type
operator()(T&& x) const
{
@@ -68,7 +68,7 @@ namespace boost { namespace fusion
{};
template <typename T>
- BOOST_FUSION_GPU_ENABLED
+ BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED
typename add_reference<typename add_const<T>::type>::type
operator()(T& x) const
{
@@ -76,7 +76,7 @@ namespace boost { namespace fusion
}
template <typename T>
- BOOST_FUSION_GPU_ENABLED
+ BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED
typename add_reference<typename add_const<T>::type>::type
operator()(T const& x) const
{
@@ -108,7 +108,8 @@ namespace boost { namespace fusion
typedef typename result_of::as_vector<transform_view_type>::type
sequence_type;
- BOOST_FUSION_GPU_ENABLED explicit nview(Sequence& val)
+ BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED
+ explicit nview(Sequence& val)
: seq(sequence_type(transform_view_type(val, transform_type())))
{}
diff --git a/boost/fusion/view/nview/nview_iterator.hpp b/boost/fusion/view/nview/nview_iterator.hpp
index c614cbbb92..aeaf4620b8 100644
--- a/boost/fusion/view/nview/nview_iterator.hpp
+++ b/boost/fusion/view/nview/nview_iterator.hpp
@@ -42,7 +42,8 @@ namespace boost { namespace fusion
typedef Sequence sequence_type;
typedef mpl_iterator<Pos> first_type;
- BOOST_FUSION_GPU_ENABLED explicit nview_iterator(Sequence& in_seq)
+ BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED
+ explicit nview_iterator(Sequence& in_seq)
: seq(in_seq) {}
Sequence& seq;
@@ -54,6 +55,15 @@ namespace boost { namespace fusion
}}
+#ifdef BOOST_FUSION_WORKAROUND_FOR_LWG_2408
+namespace std
+{
+ template <typename Sequence, typename Pos>
+ struct iterator_traits< ::boost::fusion::nview_iterator<Sequence, Pos> >
+ { };
+}
+#endif
+
#endif