]>
Commit | Line | Data |
---|---|---|
7c673cae FG |
1 | /*============================================================================= |
2 | Copyright (c) 2009 Hartmut Kaiser | |
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 | ||
8 | #if !defined(BOOST_FUSION_NVIEW_END_IMPL_SEP_24_2009_0140PM) | |
9 | #define BOOST_FUSION_NVIEW_END_IMPL_SEP_24_2009_0140PM | |
10 | ||
11 | #include <boost/fusion/support/config.hpp> | |
12 | #include <boost/fusion/sequence/intrinsic/end.hpp> | |
13 | ||
14 | namespace boost { namespace fusion | |
15 | { | |
16 | struct nview_tag; | |
17 | ||
18 | template <typename Sequence, typename Pos> | |
19 | struct nview_iterator; | |
20 | ||
21 | namespace extension | |
22 | { | |
23 | template <typename Tag> | |
24 | struct end_impl; | |
25 | ||
26 | // Unary Version | |
27 | template <> | |
28 | struct end_impl<nview_tag> | |
29 | { | |
30 | template <typename Sequence> | |
31 | struct apply | |
32 | { | |
33 | typedef typename Sequence::index_type index_type; | |
34 | ||
35 | typedef nview_iterator<Sequence, | |
36 | typename result_of::end<index_type>::type> type; | |
37 | ||
38 | BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED | |
39 | static type call(Sequence& s) | |
40 | { | |
41 | return type(s); | |
42 | } | |
43 | }; | |
44 | }; | |
45 | } | |
46 | ||
47 | }} | |
48 | ||
49 | #endif | |
50 | ||
51 |