]> git.proxmox.com Git - ceph.git/blob - ceph/src/boost/boost/fusion/container/vector/detail/value_at_impl.hpp
update sources to v12.2.3
[ceph.git] / ceph / src / boost / boost / fusion / container / vector / detail / value_at_impl.hpp
1 /*=============================================================================
2 Copyright (c) 2014 Kohei Takahashi
3
4 Distributed under the Boost Software License, Version 1.0. (See accompanying
5 file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
6 ==============================================================================*/
7 #ifndef FUSION_VALUE_AT_IMPL_16122014_1641
8 #define FUSION_VALUE_AT_IMPL_16122014_1641
9
10 #include <boost/config.hpp>
11 #include <boost/fusion/support/config.hpp>
12 #include <boost/fusion/container/vector/detail/config.hpp>
13
14 ///////////////////////////////////////////////////////////////////////////////
15 // Without variadics, we will use the PP version
16 ///////////////////////////////////////////////////////////////////////////////
17 #if !defined(BOOST_FUSION_HAS_VARIADIC_VECTOR)
18 # include <boost/fusion/container/vector/detail/cpp03/value_at_impl.hpp>
19 #else
20
21 ///////////////////////////////////////////////////////////////////////////////
22 // C++11 interface
23 ///////////////////////////////////////////////////////////////////////////////
24 #include <boost/fusion/container/vector/vector_fwd.hpp>
25 #include <boost/type_traits/declval.hpp>
26
27 namespace boost { namespace fusion
28 {
29 struct vector_tag;
30
31 namespace vector_detail
32 {
33 template <std::size_t I, typename T>
34 struct store;
35
36 template <std::size_t N, typename U>
37 static inline BOOST_FUSION_GPU_ENABLED
38 U value_at_impl(store<N, U> const volatile*);
39 }
40
41 namespace extension
42 {
43 template <typename Tag>
44 struct value_at_impl;
45
46 template <>
47 struct value_at_impl<vector_tag>
48 {
49 template <typename Sequence, typename N>
50 struct apply
51 {
52 typedef
53 decltype(vector_detail::value_at_impl<N::value>(boost::declval<Sequence*>()))
54 type;
55 };
56 };
57 }
58 }}
59
60 #endif
61 #endif
62