source: NonGTP/Boost/boost/spirit/fusion/sequence/tuple_element.hpp @ 857

Revision 857, 1.3 KB checked in by igarcia, 18 years ago (diff)
Line 
1/*=============================================================================
2    Copyright (c) 2001-2003 Joel de Guzman
3
4    Use, modification and distribution is subject to the Boost Software
5    License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
6    http://www.boost.org/LICENSE_1_0.txt)
7==============================================================================*/
8#if !defined(FUSION_SEQUENCE_TUPLE_ELEMENT_HPP)
9#define FUSION_SEQUENCE_TUPLE_ELEMENT_HPP
10
11#include <boost/spirit/fusion/sequence/value_at.hpp>
12
13namespace boost { namespace fusion
14{
15    ///////////////////////////////////////////////////////////////////////////
16    //
17    //  tuple_element metafunction
18    //
19    //      Given a constant integer N and a Sequence, returns the
20    //      tuple element type at slot N. (N is a zero based index). Usage:
21    //
22    //          tuple_element<N, Sequence>::type
23    //
24    //  This metafunction is provided here for compatibility with the
25    //  tuples TR1 specification. This metafunction forwards to
26    //  meta::value_at_c<Sequence>.
27    //
28    ///////////////////////////////////////////////////////////////////////////
29    template <int N, typename Sequence>
30    struct tuple_element : meta::value_at_c<Sequence, N> {};
31}}
32
33#endif
Note: See TracBrowser for help on using the repository browser.