mirror of
https://github.com/boostorg/fusion.git
synced 2025-07-22 00:32:53 +02:00
gpu-enable functions
This commit is contained in:
committed by
Eric Niebler
parent
867c7e5dfb
commit
c4f9f0d1b6
@ -9,6 +9,7 @@
|
||||
#if !defined(FUSION_ANY_05052005_1229)
|
||||
#define FUSION_ANY_05052005_1229
|
||||
|
||||
#include <boost/fusion/support/config.hpp>
|
||||
#include <boost/mpl/bool.hpp>
|
||||
#include <boost/fusion/sequence/intrinsic/begin.hpp>
|
||||
#include <boost/fusion/sequence/intrinsic/end.hpp>
|
||||
@ -23,6 +24,7 @@ namespace boost { namespace fusion {
|
||||
namespace detail
|
||||
{
|
||||
template <typename First, typename Last, typename F>
|
||||
BOOST_FUSION_GPU_ENABLED
|
||||
inline bool
|
||||
linear_any(First const&, Last const&, F const&, mpl::true_)
|
||||
{
|
||||
@ -30,6 +32,7 @@ namespace detail
|
||||
}
|
||||
|
||||
template <typename First, typename Last, typename F>
|
||||
BOOST_FUSION_GPU_ENABLED
|
||||
inline bool
|
||||
linear_any(First const& first, Last const& last, F& f, mpl::false_)
|
||||
{
|
||||
@ -43,6 +46,7 @@ namespace detail
|
||||
}
|
||||
|
||||
template <typename Sequence, typename F, typename Tag>
|
||||
BOOST_FUSION_GPU_ENABLED
|
||||
inline bool
|
||||
any(Sequence const& seq, F f, Tag)
|
||||
{
|
||||
@ -59,6 +63,7 @@ namespace detail
|
||||
struct unrolled_any
|
||||
{
|
||||
template <typename It, typename F>
|
||||
BOOST_FUSION_GPU_ENABLED
|
||||
static bool call(It const& it, F f)
|
||||
{
|
||||
return
|
||||
@ -74,6 +79,7 @@ namespace detail
|
||||
struct unrolled_any<3>
|
||||
{
|
||||
template <typename It, typename F>
|
||||
BOOST_FUSION_GPU_ENABLED
|
||||
static bool call(It const& it, F f)
|
||||
{
|
||||
return
|
||||
@ -87,6 +93,7 @@ namespace detail
|
||||
struct unrolled_any<2>
|
||||
{
|
||||
template <typename It, typename F>
|
||||
BOOST_FUSION_GPU_ENABLED
|
||||
static bool call(It const& it, F f)
|
||||
{
|
||||
return
|
||||
@ -99,6 +106,7 @@ namespace detail
|
||||
struct unrolled_any<1>
|
||||
{
|
||||
template <typename It, typename F>
|
||||
BOOST_FUSION_GPU_ENABLED
|
||||
static bool call(It const& it, F f)
|
||||
{
|
||||
return f(*it);
|
||||
@ -109,6 +117,7 @@ namespace detail
|
||||
struct unrolled_any<0>
|
||||
{
|
||||
template <typename It, typename F>
|
||||
BOOST_FUSION_GPU_ENABLED
|
||||
static bool call(It const&, F)
|
||||
{
|
||||
return false;
|
||||
@ -116,6 +125,7 @@ namespace detail
|
||||
};
|
||||
|
||||
template <typename Sequence, typename F>
|
||||
BOOST_FUSION_GPU_ENABLED
|
||||
inline bool
|
||||
any(Sequence const& seq, F f, random_access_traversal_tag)
|
||||
{
|
||||
|
Reference in New Issue
Block a user