[Boost-bugs] [Boost C++ Libraries] #2487: Calculate the mlp::and_ or mpl_or of a sequence of nullary logical metafunctions.

Subject: [Boost-bugs] [Boost C++ Libraries] #2487: Calculate the mlp::and_ or mpl_or of a sequence of nullary logical metafunctions.
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2008-11-08 22:41:28


#2487: Calculate the mlp::and_ or mpl_or of a sequence of nullary logical
metafunctions.
--------------------------------------+-------------------------------------
 Reporter: vicente.botet_at_[hidden] | Owner: agurtovoy
     Type: Feature Requests | Status: new
Milestone: Boost 1.38.0 | Component: mpl
  Version: Boost 1.36.0 | Severity: Cosmetic
 Keywords: |
--------------------------------------+-------------------------------------
 Do you think that these two metafunctions have a place in mpl?

 template <typename Seq>
 struct and_seq : boost::is_same<typename mpl::find_if<Seq,
 mpl::not_<mpl::_> >::type,
 typename mpl::end<Seq>::type>
                                  {};

 template <typename Seq>
 struct or_seq : mpl::not_<boost::is_same<typename mpl::find_if<Seq,
 mpl::_>::type,
 typename mpl::end<Seq>::type>
> {};

 I have attached the code and the tests.

-- 
Ticket URL: <https://svn.boost.org/trac/boost/ticket/2487>
Boost C++ Libraries <http://www.boost.org/>
Boost provides free peer-reviewed portable C++ source libraries.

This archive was generated by hypermail 2.1.7 : 2017-02-16 18:49:59 UTC