]> git.proxmox.com Git - ceph.git/blob - ceph/src/boost/libs/hana/example/less.cpp
add subtree-ish sources for 12.0.3
[ceph.git] / ceph / src / boost / libs / hana / example / less.cpp
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)
4
5 #include <boost/hana/all_of.hpp>
6 #include <boost/hana/assert.hpp>
7 #include <boost/hana/integral_constant.hpp>
8 #include <boost/hana/less.hpp>
9 #include <boost/hana/not.hpp>
10 #include <boost/hana/tuple.hpp>
11 namespace hana = boost::hana;
12
13
14 static_assert(hana::less(1, 4), "");
15 BOOST_HANA_CONSTANT_CHECK(!hana::less(hana::int_c<3>, hana::int_c<2>));
16
17 // less.than is syntactic sugar
18 static_assert(hana::all_of(hana::tuple_c<int, 1, 2, 3, 4>, hana::less.than(5)), "");
19 BOOST_HANA_CONSTANT_CHECK(hana::all_of(hana::tuple_c<int, 1, 2, 3, 4>, hana::less_equal.than(hana::int_c<4>)));
20
21 int main() { }