forked from boostorg/fusion
loop unrolling for compile time perf in any, all and none
[SVN r37820]
This commit is contained in:
@ -1,6 +1,7 @@
|
||||
/*=============================================================================
|
||||
Copyright (c) 2001-2006 Joel de Guzman
|
||||
Copyright (c) 2005 Eric Niebler
|
||||
Copyright (c) 2007 Dan Marsden
|
||||
|
||||
Distributed under the Boost Software License, Version 1.0. (See accompanying
|
||||
file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
|
||||
@ -8,9 +9,7 @@
|
||||
#if !defined(FUSION_ANY_05052005_1230)
|
||||
#define FUSION_ANY_05052005_1230
|
||||
|
||||
#include <boost/fusion/sequence/intrinsic/begin.hpp>
|
||||
#include <boost/fusion/sequence/intrinsic/end.hpp>
|
||||
#include <boost/fusion/iterator/equal_to.hpp>
|
||||
#include <boost/fusion/support/category_of.hpp>
|
||||
#include <boost/fusion/algorithm/query/detail/any.hpp>
|
||||
|
||||
namespace boost { namespace fusion
|
||||
@ -28,13 +27,7 @@ namespace boost { namespace fusion
|
||||
inline bool
|
||||
any(Sequence const& seq, F f)
|
||||
{
|
||||
return detail::any(
|
||||
fusion::begin(seq)
|
||||
, fusion::end(seq)
|
||||
, f
|
||||
, result_of::equal_to<
|
||||
typename result_of::begin<Sequence>::type
|
||||
, typename result_of::end<Sequence>::type>());
|
||||
return detail::any(seq, f, typename traits::category_of<Sequence>::type());
|
||||
}
|
||||
}}
|
||||
|
||||
|
Reference in New Issue
Block a user