]> git.proxmox.com Git - ceph.git/blame - ceph/src/boost/libs/align/include/boost/align/detail/integral_constant.hpp
bump version to 12.2.2-pve1
[ceph.git] / ceph / src / boost / libs / align / include / boost / align / detail / integral_constant.hpp
CommitLineData
7c673cae
FG
1/*
2(c) 2014-2016 Glen Joseph Fernandes
3<glenjofe -at- gmail.com>
4
5Distributed under the Boost Software
6License, Version 1.0.
7http://boost.org/LICENSE_1_0.txt
8*/
9#ifndef BOOST_ALIGN_DETAIL_INTEGRAL_CONSTANT_HPP
10#define BOOST_ALIGN_DETAIL_INTEGRAL_CONSTANT_HPP
11
12#include <boost/config.hpp>
13
14#if !defined(BOOST_NO_CXX11_HDR_TYPE_TRAITS)
15#include <type_traits>
16#endif
17
18namespace boost {
19namespace alignment {
20namespace detail {
21
22#if !defined(BOOST_NO_CXX11_HDR_TYPE_TRAITS)
23using std::integral_constant;
24#else
25template<class T, T Value>
26struct integral_constant {
27 typedef T value_type;
28 typedef integral_constant type;
29
30 BOOST_CONSTEXPR operator value_type() const BOOST_NOEXCEPT {
31 return Value;
32 }
33
34 BOOST_CONSTEXPR value_type operator()() const BOOST_NOEXCEPT {
35 return Value;
36 }
37
38 BOOST_STATIC_CONSTEXPR T value = Value;
39};
40#endif
41
42} /* .detail */
43} /* .alignment */
44} /* .boost */
45
46#endif