• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 
2 //          Copyright Oliver Kowalke 2017.
3 // Distributed under the Boost Software License, Version 1.0.
4 //    (See accompanying file LICENSE_1_0.txt or copy at
5 //          http://www.boost.org/LICENSE_1_0.txt)
6 
7 #ifndef BOOST_FIBERS_DETAIL_IS_ALL_SAME_H
8 #define BOOST_FIBERS_DETAIL_IS_ALL_SAME_H
9 
10 #include <type_traits>
11 
12 #include <boost/config.hpp>
13 
14 #include <boost/fiber/detail/config.hpp>
15 
16 #ifdef BOOST_HAS_ABI_HEADERS
17 #  include BOOST_ABI_PREFIX
18 #endif
19 
20 namespace boost {
21 namespace fibers {
22 namespace detail {
23 
24 template< typename X, typename ... Y >
25 struct is_all_same;
26 
27 template< typename X, typename Y0, typename ... Y >
28 struct is_all_same< X, Y0, Y ... > {
29     static constexpr bool value =
30         std::is_same< X, Y0 >::value && is_all_same< X, Y ... >::value;
31 };
32 
33 template< typename X, typename Y0 >
34 struct is_all_same< X, Y0 > {
35     static constexpr bool value = std::is_same< X, Y0 >::value;
36 };
37 
38 }}}
39 
40 #ifdef BOOST_HAS_ABI_HEADERS
41 #  include BOOST_ABI_SUFFIX
42 #endif
43 
44 #endif // BOOST_FIBERS_DETAIL_IS_ALL_SAME_H
45