]>
git.proxmox.com Git - ceph.git/blob - ceph/src/boost/libs/hana/example/ext/boost/mpl/list/searchable.cpp
4f6191a2e15f785f63fe6c4262c93e031fbc774a
1 // Copyright Louis Dionne 2013-2016
2 // Distributed under the Boost Software License, Version 1.0.
3 // (See accompanying file LICENSE.md or copy at http://boost.org/LICENSE_1_0.txt)
5 #include <boost/hana/assert.hpp>
6 #include <boost/hana/equal.hpp>
7 #include <boost/hana/ext/boost/mpl/list.hpp>
8 #include <boost/hana/find.hpp>
9 #include <boost/hana/find_if.hpp>
10 #include <boost/hana/optional.hpp>
11 #include <boost/hana/type.hpp>
13 #include <boost/mpl/list.hpp>
14 namespace hana
= boost::hana
;
15 namespace mpl
= boost::mpl
;
18 BOOST_HANA_CONSTANT_CHECK(
19 hana::find_if(mpl::list
<int, float, char const*>{}, hana::equal
.to(hana::type_c
<float>))
21 hana::just(hana::type_c
<float>)
24 BOOST_HANA_CONSTANT_CHECK(
25 hana::find(mpl::list
<int, float, char const*>{}, hana::type_c
<void>)