• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
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_VALUE_AT_IMPL_20060223_2025)
9 #define BOOST_FUSION_VALUE_AT_IMPL_20060223_2025
10 
11 namespace example
12 {
13     struct example_sequence_tag;
14 }
15 
16 namespace boost { namespace fusion {
17 
18     namespace extension
19     {
20         template<typename Tag>
21         struct value_at_impl;
22 
23         template<>
24         struct value_at_impl<example::example_sequence_tag>
25         {
26             template<typename Sequence, typename N>
27             struct apply;
28 
29             template<typename Sequence>
30             struct apply<Sequence, mpl::int_<0> >
31             {
32                 typedef std::string type;
33             };
34 
35             template<typename Sequence>
36             struct apply<Sequence, mpl::int_<1> >
37             {
38                 typedef int type;
39             };
40         };
41     }
42 }}
43 
44 #endif
45