]> git.proxmox.com Git - ceph.git/blob - ceph/src/boost/libs/fusion/include/boost/fusion/container/deque/detail/convert_impl.hpp
add subtree-ish sources for 12.0.3
[ceph.git] / ceph / src / boost / libs / fusion / include / boost / fusion / container / deque / detail / convert_impl.hpp
1 /*=============================================================================
2 Copyright (c) 2005-2012 Joel de Guzman
3 Copyright (c) 2005-2006 Dan Marsden
4 Copyright (c) 2015 Kohei Takahashi
5
6 Distributed under the Boost Software License, Version 1.0. (See accompanying
7 file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
8 ==============================================================================*/
9 #if !defined(FUSION_CONVERT_IMPL_20061213_2207)
10 #define FUSION_CONVERT_IMPL_20061213_2207
11
12 #include <boost/fusion/support/config.hpp>
13 #include <boost/fusion/container/deque/convert.hpp>
14 #include <boost/fusion/container/deque/deque.hpp>
15 #include <boost/fusion/sequence/intrinsic/begin.hpp>
16 #include <boost/fusion/sequence/intrinsic/end.hpp>
17
18 namespace boost { namespace fusion
19 {
20 struct deque_tag;
21
22 namespace result_of
23 {
24 template <typename Sequence>
25 struct as_deque;
26 }
27
28 namespace extension
29 {
30 template <typename T>
31 struct convert_impl;
32
33 template <>
34 struct convert_impl<deque_tag>
35 {
36 template <typename Sequence>
37 struct apply
38 {
39 typedef result_of::as_deque<Sequence> gen;
40 typedef typename gen::type type;
41
42 BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED
43 static type call(Sequence& seq)
44 {
45 return gen::call(fusion::begin(seq)
46 #if defined(BOOST_FUSION_HAS_VARIADIC_DEQUE)
47 , fusion::end(seq)
48 #endif
49 );
50 }
51 };
52 };
53 }
54 }}
55
56 #endif