// TR1 utility -*- C++ -*-
-// Copyright (C) 2004, 2005 Free Software Foundation, Inc.
+// Copyright (C) 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
//
// This file is part of the GNU ISO C++ Library. This library is free
// software; you can redistribute it and/or modify it under the
// invalidate any other reasons why the executable file might be covered by
// the GNU General Public License.
-/** @file
+/** @file tr1/utility
* This is a TR1 C++ Library header.
*/
#ifndef _TR1_UTILITY
#define _TR1_UTILITY 1
-#include "../utility"
+#include <utility>
namespace std
{
-namespace tr1
-{
+_GLIBCXX_BEGIN_NAMESPACE(_GLIBCXX_TR1)
+
template<class _Tp> class tuple_size;
template<int _Int, class _Tp> class tuple_element;
template<class _Tp1, class _Tp2>
struct tuple_size<std::pair<_Tp1, _Tp2> >
{ static const int value = 2; };
-
+
+ template<class _Tp1, class _Tp2>
+ const int tuple_size<std::pair<_Tp1, _Tp2> >::value;
+
template<class _Tp1, class _Tp2>
struct tuple_element<0, std::pair<_Tp1, _Tp2> >
{ typedef _Tp1 type; };
};
template<int _Int, class _Tp1, class _Tp2>
- typename tuple_element<_Int, std::pair<_Tp1, _Tp2> >::type&
- get(pair<_Tp1, _Tp2>& __in)
+ inline typename tuple_element<_Int, std::pair<_Tp1, _Tp2> >::type&
+ get(std::pair<_Tp1, _Tp2>& __in)
{ return __pair_get<_Int>::__get(__in); }
template<int _Int, class _Tp1, class _Tp2>
- const typename tuple_element<_Int, std::pair<_Tp1, _Tp2> >::type&
- get(const pair<_Tp1, _Tp2>& __in)
+ inline const typename tuple_element<_Int, std::pair<_Tp1, _Tp2> >::type&
+ get(const std::pair<_Tp1, _Tp2>& __in)
{ return __pair_get<_Int>::__const_get(__in); }
-}
+
+_GLIBCXX_END_NAMESPACE
}
#endif