]> git.proxmox.com Git - ceph.git/blame - ceph/src/boost/libs/fusion/include/boost/fusion/adapted/std_array/detail/at_impl.hpp
bump version to 12.2.2-pve1
[ceph.git] / ceph / src / boost / libs / fusion / include / boost / fusion / adapted / std_array / detail / at_impl.hpp
CommitLineData
7c673cae
FG
1/*=============================================================================
2 Copyright (c) 2001-2011 Joel de Guzman
3 Copyright (c) 2005-2006 Dan Marsden
4
5 Distributed under the Boost Software License, Version 1.0. (See accompanying
6 file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
7==============================================================================*/
8#if !defined(BOOST_FUSION_STD_ARRAY_AT_IMPL_01062013_1700)
9#define BOOST_FUSION_STD_ARRAY_AT_IMPL_01062013_1700
10
11#include <boost/type_traits/is_const.hpp>
12
13#include <boost/mpl/if.hpp>
14
15namespace boost { namespace fusion {
16
17 struct std_array_tag;
18
19 namespace extension
20 {
21 template<typename T>
22 struct at_impl;
23
24 template<>
25 struct at_impl<std_array_tag>
26 {
27 template<typename Sequence, typename N>
28 struct apply
29 {
30 typedef typename mpl::if_<
31 is_const<Sequence>,
32 typename Sequence::const_reference,
33 typename Sequence::reference>::type type;
34
35 static type
36 call(Sequence& seq)
37 {
38 return seq[N::value];
39 }
40 };
41 };
42 }
43}}
44
45#endif