imgtools/imglib/boostlibrary/boost/tr1/tuple.hpp
author marvin shi <marvin.shi@nokia.com>
Wed, 17 Nov 2010 14:05:07 +0800
changeset 691 9eeecb73a5d4
parent 600 6d08f4a05d93
permissions -rw-r--r--
fix ou1cimx1#651819
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
600
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
     1
//  (C) Copyright John Maddock 2005.
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
     2
//  Use, modification and distribution are subject to the
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
     3
//  Boost Software License, Version 1.0. (See accompanying file
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
     4
//  LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
     5
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
     6
#ifndef BOOST_TR1_TUPLE_HPP_INCLUDED
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
     7
#  define BOOST_TR1_TUPLE_HPP_INCLUDED
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
     8
#  include <boost/tr1/detail/config.hpp>
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
     9
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    10
#ifdef BOOST_HAS_TR1_TUPLE
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    11
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    12
#  ifdef BOOST_HAS_INCLUDE_NEXT
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    13
#     include_next BOOST_TR1_HEADER(tuple)
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    14
#  else
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    15
#     include <boost/tr1/detail/config_all.hpp>
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    16
#     include BOOST_TR1_STD_HEADER(BOOST_TR1_PATH(tuple))
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    17
#  endif
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    18
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    19
#else
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    20
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    21
#if defined(BOOST_TR1_USE_OLD_TUPLE)
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    22
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    23
#include <boost/tuple/tuple.hpp>
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    24
#include <boost/tuple/tuple_comparison.hpp>
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    25
#include <boost/type_traits/integral_constant.hpp>
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    26
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    27
namespace std{ namespace tr1{
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    28
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    29
using ::boost::tuple;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    30
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    31
// [6.1.3.2] Tuple creation functions
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    32
using ::boost::tuples::ignore;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    33
using ::boost::make_tuple;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    34
using ::boost::tie;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    35
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    36
// [6.1.3.3] Tuple helper classes
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    37
template <class T> 
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    38
struct tuple_size 
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    39
   : public ::boost::integral_constant
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    40
   < ::std::size_t, ::boost::tuples::length<T>::value>
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    41
{};
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    42
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    43
template < int I, class T>
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    44
struct tuple_element
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    45
{
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    46
   typedef typename boost::tuples::element<I,T>::type type;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    47
};
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    48
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    49
#if !BOOST_WORKAROUND(__BORLANDC__, < 0x0582)
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    50
// [6.1.3.4] Element access
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    51
using ::boost::get;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    52
#endif
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    53
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    54
} } // namespaces
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    55
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    56
#else
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    57
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    58
#include <boost/fusion/include/tuple.hpp>
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    59
#include <boost/fusion/include/std_pair.hpp>
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    60
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    61
namespace std{ namespace tr1{
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    62
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    63
using ::boost::fusion::tuple;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    64
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    65
// [6.1.3.2] Tuple creation functions
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    66
using ::boost::fusion::ignore;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    67
using ::boost::fusion::make_tuple;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    68
using ::boost::fusion::tie;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    69
using ::boost::fusion::get;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    70
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    71
// [6.1.3.3] Tuple helper classes
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    72
using ::boost::fusion::tuple_size;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    73
using ::boost::fusion::tuple_element;
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    74
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    75
}}
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    76
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    77
#endif
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    78
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    79
#endif
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    80
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    81
#endif
6d08f4a05d93 add deprecated files
jjkang
parents:
diff changeset
    82