code:
// TR1 stdarg.h -*- C++ -*-

// Copyright (C) 2006 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
// terms of the GNU General Public License as published by the
// Free Software Foundation; either version 2, or (at your option)
// any later version.

// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
// GNU General Public License for more details.

// You should have received a copy of the GNU General Public License along
// with this library; see the file COPYING.  If not, write to the Free
// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
// USA.

// As a special exception, you may use this file as part of a free software
// library without restriction.  Specifically, if other files instantiate
// templates or use macros or inline functions from this file, or you compile
// this file and link it with other files to produce an executable, this
// file does not by itself cause the resulting executable to be covered by
// the GNU General Public License.  This exception does not however
// invalidate any other reasons why the executable file might be covered by
// the GNU General Public License.

/** @file tr1/stdarg.h
 *  This is a TR1 C++ Library header.
 */

#ifndef _TR1_STDARG_H
#define _TR1_STDARG_H 1

#include <tr1/cstdarg>

#endif


code:
// TR1 stdbool.h -*- C++ -*-

// Copyright (C) 2006 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
// terms of the GNU General Public License as published by the
// Free Software Foundation; either version 2, or (at your option)
// any later version.

// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
// GNU General Public License for more details.

// You should have received a copy of the GNU General Public License along
// with this library; see the file COPYING.  If not, write to the Free
// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
// USA.

// As a special exception, you may use this file as part of a free software
// library without restriction.  Specifically, if other files instantiate
// templates or use macros or inline functions from this file, or you compile
// this file and link it with other files to produce an executable, this
// file does not by itself cause the resulting executable to be covered by
// the GNU General Public License.  This exception does not however
// invalidate any other reasons why the executable file might be covered by
// the GNU General Public License.

/** @file tr1/stdbool.h
 *  This is a TR1 C++ Library header.
 */

#ifndef _TR1_STDBOOL_H
#define _TR1_STDBOOL_H 1

#include <tr1/cstdbool>

#endif

repo_name: veiledmerc/mira

license: mit


code:
// TR1 stdint.h -*- C++ -*-

// Copyright (C) 2006 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
// terms of the GNU General Public License as published by the
// Free Software Foundation; either version 2, or (at your option)
// any later version.

// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
// GNU General Public License for more details.

// You should have received a copy of the GNU General Public License along
// with this library; see the file COPYING.  If not, write to the Free
// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
// USA.

// As a special exception, you may use this file as part of a free software
// library without restriction.  Specifically, if other files instantiate
// templates or use macros or inline functions from this file, or you compile
// this file and link it with other files to produce an executable, this
// file does not by itself cause the resulting executable to be covered by
// the GNU General Public License.  This exception does not however
// invalidate any other reasons why the executable file might be covered by
// the GNU General Public License.

/** @file tr1/stdint.h
 *  This is a TR1 C++ Library header.
 */

#ifndef _TR1_STDINT_H
#define _TR1_STDINT_H 1

#include <tr1/cstdint>

#endif


code:
// TR1 stdio.h -*- C++ -*-

// Copyright (C) 2006 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
// terms of the GNU General Public License as published by the
// Free Software Foundation; either version 2, or (at your option)
// any later version.

// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
// GNU General Public License for more details.

// You should have received a copy of the GNU General Public License along
// with this library; see the file COPYING.  If not, write to the Free
// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
// USA.

// As a special exception, you may use this file as part of a free software
// library without restriction.  Specifically, if other files instantiate
// templates or use macros or inline functions from this file, or you compile
// this file and link it with other files to produce an executable, this
// file does not by itself cause the resulting executable to be covered by
// the GNU General Public License.  This exception does not however
// invalidate any other reasons why the executable file might be covered by
// the GNU General Public License.

/** @file tr1/stdio.h
 *  This is a TR1 C++ Library header.
 */

#ifndef _TR1_STDIO_H
#define _TR1_STDIO_H 1

#include <tr1/cstdio>

#endif


code:
// TR1 stdlib.h -*- C++ -*-

// Copyright (C) 2006 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
// terms of the GNU General Public License as published by the
// Free Software Foundation; either version 2, or (at your option)
// any later version.

// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
// GNU General Public License for more details.

// You should have received a copy of the GNU General Public License along
// with this library; see the file COPYING.  If not, write to the Free
// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
// USA.

// As a special exception, you may use this file as part of a free software
// library without restriction.  Specifically, if other files instantiate
// templates or use macros or inline functions from this file, or you compile
// this file and link it with other files to produce an executable, this
// file does not by itself cause the resulting executable to be covered by
// the GNU General Public License.  This exception does not however
// invalidate any other reasons why the executable file might be covered by
// the GNU General Public License.

/** @file tr1/stdlib.h
 *  This is a TR1 C++ Library header.
 */

#ifndef _TR1_STDLIB_H
#define _TR1_STDLIB_H 1

#include <tr1/cstdlib>

#if _GLIBCXX_HOSTED

#if _GLIBCXX_USE_C99

using std::tr1::atoll;
using std::tr1::strtoll;
using std::tr1::strtoull;

using std::tr1::abs;
#if !_GLIBCXX_USE_C99_LONG_LONG_DYNAMIC
using std::tr1::div;
#endif

#endif

#endif

#endif


code:
// TR1 tgmath.h -*- C++ -*-

// Copyright (C) 2006 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
// terms of the GNU General Public License as published by the
// Free Software Foundation; either version 2, or (at your option)
// any later version.

// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
// GNU General Public License for more details.

// You should have received a copy of the GNU General Public License along
// with this library; see the file COPYING.  If not, write to the Free
// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
// USA.

// As a special exception, you may use this file as part of a free software
// library without restriction.  Specifically, if other files instantiate
// templates or use macros or inline functions from this file, or you compile
// this file and link it with other files to produce an executable, this
// file does not by itself cause the resulting executable to be covered by
// the GNU General Public License.  This exception does not however
// invalidate any other reasons why the executable file might be covered by
// the GNU General Public License.

/** @file tr1/tgmath.h
 *  This is a TR1 C++ Library header.
 */

#ifndef _TR1_TGMATH_H
#define _TR1_TGMATH_H 1

#include <tr1/ctgmath>

#endif


code:
// class template tuple -*- C++ -*-

// Copyright (C) 2004, 2005 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
// terms of the GNU General Public License as published by the
// Free Software Foundation; either version 2, or (at your option)
// any later version.

// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
// GNU General Public License for more details.

// You should have received a copy of the GNU General Public License along
// with this library; see the file COPYING.  If not, write to the Free
// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
// USA.

// As a special exception, you may use this file as part of a free software
// library without restriction.  Specifically, if other files instantiate
// templates or use macros or inline functions from this file, or you compile
// this file and link it with other files to produce an executable, this
// file does not by itself cause the resulting executable to be covered by
// the GNU General Public License.  This exception does not however
// invalidate any other reasons why the executable file might be covered by
// the GNU General Public License.

/** @file tr1/tuple
*  This is a TR1 C++ Library header.
*/

// Chris Jefferson <chris@bubblescope.net>

#ifndef _TR1_TUPLE
#define _TR1_TUPLE 1

#include <tr1/utility>
#include <tr1/ref_fwd.h>

namespace std
{
_GLIBCXX_BEGIN_NAMESPACE(tr1)

 // An implementation specific class which is used in the tuple class
 // when the tuple is not maximum possible size.
 struct _NullClass { };

 /// Gives the type of the ith element of a given tuple type.
 template<int __i, typename _Tp>
   struct tuple_element;

 /// Finds the size of a given tuple type.
 template<typename _Tp>
   struct tuple_size;

 // Adds a const reference to a non-reference type.
 template<typename _Tp>
   struct __add_c_ref
   { typedef const _Tp& type; };

 template<typename _Tp>
   struct __add_c_ref<_Tp&>
   { typedef _Tp& type; };

 // Adds a reference to a non-reference type.
 template<typename _Tp>
   struct __add_ref
   { typedef _Tp& type; };

 template<typename _Tp>
   struct __add_ref<_Tp&>
   { typedef _Tp& type; };

 // Class used in the implementation of get
 template<int __i, typename _Tp>
   struct __get_helper;

 // Returns a const reference to the ith element of a tuple.
 // Any const or non-const ref elements are returned with their original type.

 // This class helps construct the various comparison operations on tuples
 template<int __check_equal_size, int __i, int __j, typename _Tp, typename _Up>
   struct __tuple_compare;

 // Helper which adds a reference to a type when given a reference_wrapper
 template<typename _Tp>
   struct __strip_reference_wrapper
   {
       typedef _Tp __type;
   };

 template<typename _Tp>
   struct __strip_reference_wrapper<reference_wrapper<_Tp> >
   {
     typedef _Tp& __type;
   };

 template<typename _Tp>
   struct __strip_reference_wrapper<const reference_wrapper<_Tp> >
   {
       typedef _Tp& __type;
   };

  #include "tuple_defs.h"

 template<int __i, int __j, typename _Tp, typename _Up>
   struct __tuple_compare<0, __i, __j, _Tp, _Up>
   {
     static bool __eq(const _Tp& __t, const _Up& __u)
     {
       return get<__i>(__t) == get<__i>(__u) &&
          __tuple_compare<0, __i+1, __j, _Tp, _Up>::__eq(__t, __u);
     }
     static bool __less(const _Tp& __t, const _Up& __u)
     {
       return (get<__i>(__t) < get<__i>(__u)) || !(get<__i>(__u) < get<__i>(__t)) &&
          __tuple_compare<0, __i+1, __j, _Tp, _Up>::__less(__t, __u);
     }
   };

 template<int __i, typename _Tp, typename _Up>
   struct __tuple_compare<0, __i, __i, _Tp, _Up>
   {
     static bool __eq(const _Tp&, const _Up&)
     { return true; }
     static bool __less(const _Tp&, const _Up&)
     { return false; }
   };

 // A class (and instance) which can be used in 'tie' when an element
 // of a tuple is not required
 struct swallow_assign
 {
   template<class T>
   swallow_assign&
     operator=(const T&)
     { return *this; }
 };

 // TODO: Put this in some kind of shared file.
 namespace
 {
   swallow_assign ignore;
 }; // anonymous namespace

_GLIBCXX_END_NAMESPACE
}

#define _GLIBCXX_CAT(x,y) _GLIBCXX_CAT2(x,y)
#define _GLIBCXX_CAT2(x,y) x##y
#define _SHORT_REPEAT
#define _GLIBCXX_REPEAT_HEADER <tr1/tuple_iterate.h>
#include <tr1/repeat.h>
#undef _GLIBCXX_REPEAT_HEADER
#undef _SHORT_REPEAT

#include <tr1/functional>

#endif


code:
// class template tuple -*- C++ -*-

// Copyright (C) 2004, 2005 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
// terms of the GNU General Public License as published by the
// Free Software Foundation; either version 2, or (at your option)
// any later version.

// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
// GNU General Public License for more details.

// You should have received a copy of the GNU General Public License along
// with this library; see the file COPYING.  If not, write to the Free
// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
// USA.

// As a special exception, you may use this file as part of a free software
// library without restriction.  Specifically, if other files instantiate
// templates or use macros or inline functions from this file, or you compile
// this file and link it with other files to produce an executable, this
// file does not by itself cause the resulting executable to be covered by
// the GNU General Public License.  This exception does not however
// invalidate any other reasons why the executable file might be covered by
// the GNU General Public License.

/** @file tr1/tuple_defs.h
 *  This is an internal header file, included by other library headers.
 *  You should not attempt to use it directly.
 */

#ifndef _GLIBCXX_REPEAT_HEADER
#  define _GLIBCXX_REPEAT_HEADER "tuple_defs.h"
#  include "repeat.h"
#  undef _GLIBCXX_REPEAT_HEADER
#endif

#ifdef _GLIBCXX_LAST_INCLUDE
// Chris Jefferson <chris@bubblescope.net>
   template<_GLIBCXX_TEMPLATE_PARAMS_NULL_CLASS> class tuple;

   // Returns a const reference to the ith element of a tuple.
   // Any const or non-const ref elements are returned with their original type.
   template<int __i, _GLIBCXX_TEMPLATE_PARAMS>
   typename __add_ref<typename tuple_element<__i, tuple<_GLIBCXX_TEMPLATE_ARGS> >::type>::type
   get(tuple<_GLIBCXX_TEMPLATE_ARGS>& __t)
   {
     return __get_helper<__i, tuple<_GLIBCXX_TEMPLATE_ARGS> >::get_value(__t);
   }

   template<int __i, _GLIBCXX_TEMPLATE_PARAMS>
   typename __add_c_ref<typename tuple_element<__i, tuple<_GLIBCXX_TEMPLATE_ARGS> >::type>::type
   get(const tuple<_GLIBCXX_TEMPLATE_ARGS>& __t)
   {
     return __get_helper<__i, tuple<_GLIBCXX_TEMPLATE_ARGS> >::get_value(__t);
   }

 template<_GLIBCXX_TEMPLATE_PARAMS, _GLIBCXX_TEMPLATE_PARAMS_U>
 bool
 operator==(const tuple<_GLIBCXX_TEMPLATE_ARGS>& __t,
            const tuple<_GLIBCXX_TEMPLATE_ARGS_U>& __u)
 {
   typedef tuple<_GLIBCXX_TEMPLATE_ARGS> _Tp;
   typedef tuple<_GLIBCXX_TEMPLATE_ARGS_U> _Up;
   return __tuple_compare<tuple_size<_Tp>::value - tuple_size<_Tp>::value, 0,
                          tuple_size<_Tp>::value, _Tp, _Up>::__eq(__t, __u);
 }

 template<_GLIBCXX_TEMPLATE_PARAMS, _GLIBCXX_TEMPLATE_PARAMS_U>
 bool
 operator<(const tuple<_GLIBCXX_TEMPLATE_ARGS>& __t,
           const tuple<_GLIBCXX_TEMPLATE_ARGS_U>& __u)
 {
   typedef tuple<_GLIBCXX_TEMPLATE_ARGS> _Tp;
   typedef tuple<_GLIBCXX_TEMPLATE_ARGS_U> _Up;
   return __tuple_compare<tuple_size<_Tp>::value - tuple_size<_Tp>::value, 0,
                          tuple_size<_Tp>::value, _Tp, _Up>::__less(__t, __u);
 }

 template<_GLIBCXX_TEMPLATE_PARAMS, _GLIBCXX_TEMPLATE_PARAMS_U>
 bool
 operator!=(const tuple<_GLIBCXX_TEMPLATE_ARGS>& __t,
            const tuple<_GLIBCXX_TEMPLATE_ARGS_U>& __u)
 { return !(__t == __u); }

 template<_GLIBCXX_TEMPLATE_PARAMS, _GLIBCXX_TEMPLATE_PARAMS_U>
 bool
 operator>(const tuple<_GLIBCXX_TEMPLATE_ARGS>& __t,
           const tuple<_GLIBCXX_TEMPLATE_ARGS_U>& __u)
 { return __u < __t; }

 template<_GLIBCXX_TEMPLATE_PARAMS, _GLIBCXX_TEMPLATE_PARAMS_U>
 bool
 operator<=(const tuple<_GLIBCXX_TEMPLATE_ARGS>& __t,
            const tuple<_GLIBCXX_TEMPLATE_ARGS_U>& __u)
 { return !(__u < __t); }

 template<_GLIBCXX_TEMPLATE_PARAMS, _GLIBCXX_TEMPLATE_PARAMS_U>
 bool
 operator>=(const tuple<_GLIBCXX_TEMPLATE_ARGS>& __t,
            const tuple<_GLIBCXX_TEMPLATE_ARGS_U>& __u)
 { return !(__t < __u); }

 template<_GLIBCXX_TEMPLATE_PARAMS_NULL_CLASS>
   struct __stripped_tuple_type
   {
     typedef tuple<_GLIBCXX_TEMPLATE_ARGS_STRIPPED>      __type;
   };

#endif


code:
// class template tuple -*- C++ -*-

// Copyright (C) 2004, 2005, 2006 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
// terms of the GNU General Public License as published by the
// Free Software Foundation; either version 2, or (at your option)
// any later version.

// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
// GNU General Public License for more details.

// You should have received a copy of the GNU General Public License along
// with this library; see the file COPYING.  If not, write to the Free
// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
// USA.

// As a special exception, you may use this file as part of a free software
// library without restriction.  Specifically, if other files instantiate
// templates or use macros or inline functions from this file, or you compile
// this file and link it with other files to produce an executable, this
// file does not by itself cause the resulting executable to be covered by
// the GNU General Public License.  This exception does not however
// invalidate any other reasons why the executable file might be covered by
// the GNU General Public License.

/** @file tr1/tuple_iterate.h
 *  This is an internal header file, included by other library headers.
 *  You should not attempt to use it directly.
 */

// Chris Jefferson <chris@bubblescope.net>

namespace std
{
_GLIBCXX_BEGIN_NAMESPACE(tr1)

/// @brief class tuple_size
template<_GLIBCXX_TEMPLATE_PARAMS>
  struct tuple_size<tuple<_GLIBCXX_TEMPLATE_ARGS> >
  { static const int value = _GLIBCXX_NUM_ARGS; };

#if _GLIBCXX_NUM_ARGS > 0
template<_GLIBCXX_TEMPLATE_PARAMS>
  const int tuple_size<tuple<_GLIBCXX_TEMPLATE_ARGS> >::value;
#endif

template<_GLIBCXX_TEMPLATE_PARAMS>
#ifdef _GLIBCXX_LAST_INCLUDE
  class tuple
#else
  class tuple<_GLIBCXX_TEMPLATE_ARGS>
#endif
  {
    _GLIBCXX_BIND_MEMBERS

  public:
    tuple()
    { }

#if _GLIBCXX_NUM_ARGS == 2
    template<typename _U1, typename _U2>
      tuple(const std::pair<_U1, _U2>& __u) :
      _M_arg1(__u.first), _M_arg2(__u.second)
      { }

    template<typename _U1, typename _U2>
      tuple&
      operator=(const std::pair<_U1, _U2>& __u)
      {
	_M_arg1 = __u.first;
	_M_arg2 = __u.second;
	return *this;
      }
#endif

#if _GLIBCXX_NUM_ARGS > 0
    explicit tuple(_GLIBCXX_TUPLE_ADD_CREF) :
      _GLIBCXX_BIND_MEMBERS_INIT
    { }

    template<_GLIBCXX_TEMPLATE_PARAMS_U>
      tuple(const tuple<_GLIBCXX_TEMPLATE_ARGS_U>& __in) :
      _GLIBCXX_TUPLE_COPY_INIT
    { }

    template<_GLIBCXX_TEMPLATE_PARAMS_U>
      tuple&
      operator=(const tuple<_GLIBCXX_TEMPLATE_ARGS_U>& __in)
      {
        _GLIBCXX_TUPLE_ASSIGN
        return *this;
      }

    tuple(const tuple& __in) :
      _GLIBCXX_TUPLE_COPY_INIT
    { }

#else

    tuple(const tuple&)
    { }

#endif

    tuple&
    operator=(const tuple& __in __attribute__((__unused__)) )
    {
      _GLIBCXX_TUPLE_ASSIGN
        return *this;
    }

    template<int __i, typename __Type>
      friend class __get_helper;

    template<_GLIBCXX_TUPLE_ALL_TEMPLATE_PARAMS_UNNAMED>
      friend class tuple;
  };

#ifndef _GLIBCXX_LAST_INCLUDE

template<typename _Tp>
    struct __get_helper<_GLIBCXX_NUM_ARGS, _Tp>
    {
      static typename __add_ref<typename tuple_element<_GLIBCXX_NUM_ARGS,
                                                       _Tp>::type>::type
      get_value(_Tp& __in)
      { return __in._GLIBCXX_CAT(_M_arg,_GLIBCXX_NUM_ARGS_PLUS_1); }

      static typename __add_c_ref<typename tuple_element<_GLIBCXX_NUM_ARGS,
                                                         _Tp>::type>::type
      get_value(const _Tp& __in)
      { return __in._GLIBCXX_CAT(_M_arg,_GLIBCXX_NUM_ARGS_PLUS_1); }
    };

/// @brief class tuple_element
template<_GLIBCXX_TUPLE_ALL_TEMPLATE_PARAMS>
   struct tuple_element<_GLIBCXX_NUM_ARGS, tuple<_GLIBCXX_TUPLE_ALL_TEMPLATE_ARGS> >
  { typedef _GLIBCXX_T_NUM_ARGS_PLUS_1 type; };

#endif
#if _GLIBCXX_NUM_ARGS == 0

tuple<>
inline make_tuple()
{ return tuple<>(); }

tuple<>
inline tie()
{ return tuple<>(); }
#else

template<_GLIBCXX_TEMPLATE_PARAMS>
  typename __stripped_tuple_type<_GLIBCXX_TEMPLATE_ARGS>::__type
  inline make_tuple(_GLIBCXX_PARAMS)
  {
    return typename __stripped_tuple_type<_GLIBCXX_TEMPLATE_ARGS>::
      __type(_GLIBCXX_ARGS);
  }

template<_GLIBCXX_TEMPLATE_PARAMS>
  tuple<_GLIBCXX_REF_TEMPLATE_ARGS>
  inline tie(_GLIBCXX_REF_PARAMS)
  { return make_tuple(_GLIBCXX_REF_WRAP_PARAMS); }
#endif

_GLIBCXX_END_NAMESPACE
}


code:
// TR1 type_traits -*- C++ -*-

// Copyright (C) 2004, 2005, 2006 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
// terms of the GNU General Public License as published by the
// Free Software Foundation; either version 2, or (at your option)
// any later version.

// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
// GNU General Public License for more details.

// You should have received a copy of the GNU General Public License along
// with this library; see the file COPYING.  If not, write to the Free
// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
// USA.

// As a special exception, you may use this file as part of a free software
// library without restriction.  Specifically, if other files instantiate
// templates or use macros or inline functions from this file, or you compile
// this file and link it with other files to produce an executable, this
// file does not by itself cause the resulting executable to be covered by
// the GNU General Public License.  This exception does not however
// invalidate any other reasons why the executable file might be covered by
// the GNU General Public License.

/** @file tr1/type_traits
 *  This is a TR1 C++ Library header.
 */

#ifndef _TR1_TYPE_TRAITS
#define _TR1_TYPE_TRAITS 1

#include <bits/c++config.h>
#include <tr1/type_traits_fwd.h>

// namespace std::tr1
namespace std
{
_GLIBCXX_BEGIN_NAMESPACE(tr1)

  // For use in __in_array and elsewhere.
  struct __sfinae_types
  {
    typedef char __one;
    typedef struct { char __arr[2]; } __two;
  };

  template<typename _Tp>
    struct __in_array
    : public __sfinae_types
    {
    private:
      template<typename _Up>
        static __one __test(_Up(*)[1]);
      template<typename>
        static __two __test(...);

    public:
      static const bool __value = sizeof(__test<_Tp>(0)) == 1;
    };

#define _DEFINE_SPEC_BODY(_Value)                                    \
    : public integral_constant<bool, _Value> { };

#define _DEFINE_SPEC_0_HELPER(_Spec, _Value)                         \
  template<>                                                         \
    struct _Spec                                                     \
    _DEFINE_SPEC_BODY(_Value)

#define _DEFINE_SPEC_1_HELPER(_Spec, _Value)                         \
  template<typename _Tp>                                             \
    struct _Spec                                                     \
    _DEFINE_SPEC_BODY(_Value)

#define _DEFINE_SPEC_2_HELPER(_Spec, _Value)                         \
  template<typename _Tp, typename _Cp>                               \
    struct _Spec                                                     \
    _DEFINE_SPEC_BODY(_Value)

#define _DEFINE_SPEC(_Order, _Trait, _Type, _Value)                  \
  _DEFINE_SPEC_##_Order##_HELPER(_Trait<_Type>, _Value)              \
  _DEFINE_SPEC_##_Order##_HELPER(_Trait<_Type const>, _Value)        \
  _DEFINE_SPEC_##_Order##_HELPER(_Trait<_Type volatile>, _Value)     \
  _DEFINE_SPEC_##_Order##_HELPER(_Trait<_Type const volatile>, _Value)

  /// @brief  helper classes [4.3].
  template<typename _Tp, _Tp __v>
    struct integral_constant
    {
      static const _Tp                      value = __v;
      typedef _Tp                           value_type;
      typedef integral_constant<_Tp, __v>   type;
    };
  typedef integral_constant<bool, true>     true_type;
  typedef integral_constant<bool, false>    false_type;

  template<typename _Tp, _Tp __v>
    const _Tp integral_constant<_Tp, __v>::value;

  /// @brief  primary type categories [4.5.1].
  template<typename>
    struct is_void
    : public false_type { };
  _DEFINE_SPEC(0, is_void, void, true)

  template<typename>
    struct is_integral
    : public false_type { };
  _DEFINE_SPEC(0, is_integral, bool, true)
  _DEFINE_SPEC(0, is_integral, char, true)
  _DEFINE_SPEC(0, is_integral, signed char, true)
  _DEFINE_SPEC(0, is_integral, unsigned char, true)
#ifdef _GLIBCXX_USE_WCHAR_T
  _DEFINE_SPEC(0, is_integral, wchar_t, true)
#endif
  _DEFINE_SPEC(0, is_integral, short, true)
  _DEFINE_SPEC(0, is_integral, unsigned short, true)
  _DEFINE_SPEC(0, is_integral, int, true)
  _DEFINE_SPEC(0, is_integral, unsigned int, true)
  _DEFINE_SPEC(0, is_integral, long, true)
  _DEFINE_SPEC(0, is_integral, unsigned long, true)
  _DEFINE_SPEC(0, is_integral, long long, true)
  _DEFINE_SPEC(0, is_integral, unsigned long long, true)

  template<typename>
    struct is_floating_point
    : public false_type { };
  _DEFINE_SPEC(0, is_floating_point, float, true)
  _DEFINE_SPEC(0, is_floating_point, double, true)
  _DEFINE_SPEC(0, is_floating_point, long double, true)

  template<typename>
    struct is_array
    : public false_type { };

  template<typename _Tp, std::size_t _Size>
    struct is_array<_Tp[_Size]>
    : public true_type { };

  template<typename _Tp>
    struct is_array<_Tp[]>
    : public true_type { };

  template<typename>
    struct is_pointer
    : public false_type { };
  _DEFINE_SPEC(1, is_pointer, _Tp*, true)

  template<typename>
    struct is_reference
    : public false_type { };

  template<typename _Tp>
    struct is_reference<_Tp&>
    : public true_type { };

  template<typename>
    struct is_member_object_pointer
    : public false_type { };
  _DEFINE_SPEC(2, is_member_object_pointer, _Tp _Cp::*,
	       !is_function<_Tp>::value)

  template<typename>
    struct is_member_function_pointer
    : public false_type { };
  _DEFINE_SPEC(2, is_member_function_pointer, _Tp _Cp::*,
	       is_function<_Tp>::value)

  template<typename _Tp>
    struct is_enum
    : public integral_constant<bool, !(is_fundamental<_Tp>::value
				       || is_array<_Tp>::value
				       || is_pointer<_Tp>::value
				       || is_reference<_Tp>::value
				       || is_member_pointer<_Tp>::value
				       || is_function<_Tp>::value
				       || __is_union_or_class<_Tp>::value)>
    { };

  template<typename>
    struct is_union { };

  template<typename>
    struct is_class { };

  template<typename _Tp>
    struct is_function
    : public integral_constant<bool, !(__in_array<_Tp>::__value
				       || __is_union_or_class<_Tp>::value
				       || is_reference<_Tp>::value
				       || is_void<_Tp>::value)>
    { };

  /// @brief  composite type traits [4.5.2].
  template<typename _Tp>
    struct is_arithmetic
    : public integral_constant<bool, (is_integral<_Tp>::value
				      || is_floating_point<_Tp>::value)>
    { };

  template<typename _Tp>
    struct is_fundamental
    : public integral_constant<bool, (is_arithmetic<_Tp>::value
				      || is_void<_Tp>::value)>
    { };

  template<typename _Tp>
    struct is_object
    : public integral_constant<bool, !(is_function<_Tp>::value
				       || is_reference<_Tp>::value
				       || is_void<_Tp>::value)>
    { };

  template<typename _Tp>
    struct is_scalar
    : public integral_constant<bool, (is_arithmetic<_Tp>::value
				      || is_enum<_Tp>::value
				      || is_pointer<_Tp>::value
				      || is_member_pointer<_Tp>::value)>
    { };

  template<typename _Tp>
    struct is_compound
    : public integral_constant<bool, !is_fundamental<_Tp>::value> { };

  template<typename _Tp>
    struct is_member_pointer
    : public integral_constant<bool,
			       (is_member_object_pointer<_Tp>::value
				|| is_member_function_pointer<_Tp>::value)>
    { };

  template<typename _Tp>
    struct __is_union_or_class_helper
    : public __sfinae_types
    {
    private:
      template<typename _Up>
        static __one __test(int _Up::*);
      template<typename>
        static __two __test(...);

    public:
      static const bool __value = sizeof(__test<_Tp>(0)) == 1;
    };

  // Extension.
  template<typename _Tp>
    struct __is_union_or_class
    : public integral_constant<bool, __is_union_or_class_helper<_Tp>::__value>
    { };

  /// @brief  type properties [4.5.3].
  template<typename>
    struct is_const
    : public false_type { };

  template<typename _Tp>
    struct is_const<_Tp const>
    : public true_type { };

  template<typename>
    struct is_volatile
    : public false_type { };

  template<typename _Tp>
    struct is_volatile<_Tp volatile>
    : public true_type { };

  template<typename _Tp>
    struct is_pod
    : public integral_constant<bool, (is_void<_Tp>::value
				      || is_scalar<typename
				      remove_all_extents<_Tp>::type>::value)>
    { };

  // NB: Without compiler support we cannot tell union from class types,
  // and is_empty and is_polymorphic don't work at all with the former.
  template<typename _Tp, bool = !__is_union_or_class<_Tp>::value>
    struct __is_empty_helper
    {
    private:
      template<typename>
        struct __first { };
      template<typename _Up>
        struct __second
        : public _Up { };

    public:
      static const bool __value = sizeof(__first<_Tp>) == sizeof(__second<_Tp>);
    };

  template<typename _Tp>
    struct __is_empty_helper<_Tp, true>
    { static const bool __value = false; };

  template<typename _Tp>
    struct is_empty
    : public integral_constant<bool, __is_empty_helper<_Tp>::__value>
    { };

  template<typename _Tp, bool = !__is_union_or_class<_Tp>::value>
    struct __is_polymorphic_helper
    {
    private:
      template<typename _Up>
        struct __first
        : public _Up { };
      template<typename _Up>
        struct __second
        : public _Up
	{
	  virtual void __dummy();
	  virtual ~__second() throw();
	};

    public:
      static const bool __value = sizeof(__first<_Tp>) == sizeof(__second<_Tp>);
    };

  template<typename _Tp>
    struct __is_polymorphic_helper<_Tp, true>
    { static const bool __value = false; };

  template<typename _Tp>
    struct is_polymorphic
    : public integral_constant<bool, __is_polymorphic_helper<_Tp>::__value>
    { };

  // Exploit the resolution DR core/337.
  template<typename _Tp>
    struct is_abstract
    : public integral_constant<bool, (!__in_array<_Tp>::__value
				      && __is_union_or_class<_Tp>::value)> { };

  template<typename _Tp>
    struct has_trivial_constructor
    : public integral_constant<bool, is_pod<_Tp>::value> { };

  template<typename _Tp>
    struct has_trivial_copy
    : public integral_constant<bool, is_pod<_Tp>::value> { };

  template<typename _Tp>
    struct has_trivial_assign
    : public integral_constant<bool, is_pod<_Tp>::value> { };

  template<typename _Tp>
    struct has_trivial_destructor
    : public integral_constant<bool, is_pod<_Tp>::value> { };

  template<typename _Tp>
    struct has_nothrow_constructor
    : public integral_constant<bool, is_pod<_Tp>::value> { };

  template<typename _Tp>
    struct has_nothrow_copy
    : public integral_constant<bool, is_pod<_Tp>::value> { };

  template<typename _Tp>
    struct has_nothrow_assign
    : public integral_constant<bool, is_pod<_Tp>::value> { };

  template<typename>
    struct has_virtual_destructor
    : public false_type { };

  template<typename>
    struct is_signed
    : public false_type { };
  _DEFINE_SPEC(0, is_signed, signed char, true)
  _DEFINE_SPEC(0, is_signed, short, true)
  _DEFINE_SPEC(0, is_signed, int, true)
  _DEFINE_SPEC(0, is_signed, long, true)
  _DEFINE_SPEC(0, is_signed, long long, true)

  template<typename>
    struct is_unsigned
    : public false_type { };
  _DEFINE_SPEC(0, is_unsigned, unsigned char, true)
  _DEFINE_SPEC(0, is_unsigned, unsigned short, true)
  _DEFINE_SPEC(0, is_unsigned, unsigned int, true)
  _DEFINE_SPEC(0, is_unsigned, unsigned long, true)
  _DEFINE_SPEC(0, is_unsigned, unsigned long long, true)

  template<typename _Tp>
    struct alignment_of
    : public integral_constant<std::size_t, __alignof__(_Tp)> { };

  template<typename>
    struct rank
    : public integral_constant<std::size_t, 0> { };

  template<typename _Tp, std::size_t _Size>
    struct rank<_Tp[_Size]>
    : public integral_constant<std::size_t, 1 + rank<_Tp>::value> { };

  template<typename _Tp>
    struct rank<_Tp[]>
    : public integral_constant<std::size_t, 1 + rank<_Tp>::value> { };

  template<typename, unsigned>
    struct extent
    : public integral_constant<std::size_t, 0> { };

  template<typename _Tp, unsigned _Uint, std::size_t _Size>
    struct extent<_Tp[_Size], _Uint>
    : public integral_constant<std::size_t,
			       _Uint == 0 ? _Size : extent<_Tp,
							   _Uint - 1>::value>
    { };

  template<typename _Tp, unsigned _Uint>
    struct extent<_Tp[], _Uint>
    : public integral_constant<std::size_t,
			       _Uint == 0 ? 0 : extent<_Tp,
						       _Uint - 1>::value>
    { };

  /// @brief  relationships between types [4.6].
  template<typename, typename>
    struct is_same
    : public false_type { };

  template<typename _Tp>
    struct is_same<_Tp, _Tp>
    : public true_type { };

  // See Daveed Vandevoorde explanation in http://tinyurl.com/502f.
  // Also see Rani Sharoni in http://tinyurl.com/6jvyq.
  template<typename _Base, typename _Derived,
	   bool = (!__is_union_or_class<_Base>::value
		   || !__is_union_or_class<_Derived>::value
		   || is_same<_Base, _Derived>::value)>
    struct __is_base_of_helper
    : public __sfinae_types
    {
    private:
      typedef typename remove_cv<_Base>::type     _NoCv_Base;
      typedef typename remove_cv<_Derived>::type  _NoCv_Derived;

      template<typename _Up>
        static __one __test(_NoCv_Derived&, _Up);
      static __two __test(_NoCv_Base&, int);

      struct _Conv
      {
	operator _NoCv_Derived&();
	operator _NoCv_Base&() const;
      };

    public:
      static const bool __value = sizeof(__test(_Conv(), 0)) == 1;
    };

  template<typename _Base, typename _Derived>
    struct __is_base_of_helper<_Base, _Derived, true>
    { static const bool __value = is_same<_Base, _Derived>::value; };

  template<typename _Base, typename _Derived>
    struct is_base_of
    : public integral_constant<bool,
			       __is_base_of_helper<_Base, _Derived>::__value>
    { };

  template<typename _From, typename _To>
    struct __is_convertible_simple
    : public __sfinae_types
    {
    private:
      static __one __test(_To);
      static __two __test(...);
      static _From __makeFrom();

    public:
      static const bool __value = sizeof(__test(__makeFrom())) == 1;
    };

  template<typename _Tp>
    struct __is_int_or_cref
    {
      typedef typename remove_reference<_Tp>::type __rr_Tp;
      static const bool __value = (is_integral<_Tp>::value
				   || (is_integral<__rr_Tp>::value
				       && is_const<__rr_Tp>::value
				       && !is_volatile<__rr_Tp>::value));
    };

  template<typename _From, typename _To,
	   bool = (is_void<_From>::value || is_void<_To>::value
		   || is_function<_To>::value || is_array<_To>::value
		   // This special case is here only to avoid warnings.
		   || (is_floating_point<typename
		       remove_reference<_From>::type>::value
		       && __is_int_or_cref<_To>::__value))>
    struct __is_convertible_helper
    {
      // "An imaginary lvalue of type From...".
      static const bool __value = (__is_convertible_simple<typename
				   add_reference<_From>::type, _To>::__value);
    };

  template<typename _From, typename _To>
    struct __is_convertible_helper<_From, _To, true>
    { static const bool __value = (is_void<_To>::value
				   || (__is_int_or_cref<_To>::__value
				       && !is_void<_From>::value)); };

  template<typename _From, typename _To>
    struct is_convertible
    : public integral_constant<bool,
			       __is_convertible_helper<_From, _To>::__value>
    { };

  /// @brief  const-volatile modifications [4.7.1].
  template<typename _Tp>
    struct remove_const
    { typedef _Tp     type; };

  template<typename _Tp>
    struct remove_const<_Tp const>
    { typedef _Tp     type; };

  template<typename _Tp>
    struct remove_volatile
    { typedef _Tp     type; };

  template<typename _Tp>
    struct remove_volatile<_Tp volatile>
    { typedef _Tp     type; };

  template<typename _Tp>
    struct remove_cv
    {
      typedef typename
      remove_const<typename remove_volatile<_Tp>::type>::type     type;
    };

  template<typename _Tp>
    struct add_const
    { typedef _Tp const     type; };

  template<typename _Tp>
    struct add_volatile
    { typedef _Tp volatile     type; };

  template<typename _Tp>
    struct add_cv
    {
      typedef typename
      add_const<typename add_volatile<_Tp>::type>::type     type;
    };

  /// @brief  reference modifications [4.7.2].
  template<typename _Tp>
    struct remove_reference
    { typedef _Tp     type; };

  template<typename _Tp>
    struct remove_reference<_Tp&>
    { typedef _Tp     type; };

  // NB: Careful with reference to void.
  template<typename _Tp, bool = (is_void<_Tp>::value
				 || is_reference<_Tp>::value)>
    struct __add_reference_helper
    { typedef _Tp&    type; };

  template<typename _Tp>
    struct __add_reference_helper<_Tp, true>
    { typedef _Tp     type; };

  template<typename _Tp>
    struct add_reference
    : public __add_reference_helper<_Tp>
    { };

  /// @brief  array modifications [4.7.3].
  template<typename _Tp>
    struct remove_extent
    { typedef _Tp     type; };

  template<typename _Tp, std::size_t _Size>
    struct remove_extent<_Tp[_Size]>
    { typedef _Tp     type; };

  template<typename _Tp>
    struct remove_extent<_Tp[]>
    { typedef _Tp     type; };

  template<typename _Tp>
    struct remove_all_extents
    { typedef _Tp     type; };

  template<typename _Tp, std::size_t _Size>
    struct remove_all_extents<_Tp[_Size]>
    { typedef typename remove_all_extents<_Tp>::type     type; };

  template<typename _Tp>
    struct remove_all_extents<_Tp[]>
    { typedef typename remove_all_extents<_Tp>::type     type; };

  /// @brief  pointer modifications [4.7.4].
#undef _DEFINE_SPEC_BODY
#define _DEFINE_SPEC_BODY(_Value)      \
    { typedef _Tp     type; };

  template<typename _Tp>
    struct remove_pointer
    { typedef _Tp     type; };
  _DEFINE_SPEC(1, remove_pointer, _Tp*, false)

  template<typename _Tp>
    struct add_pointer
    { typedef typename remove_reference<_Tp>::type*     type; };

  /// @brief  other transformations [4.8].

  // Due to c++/19163 and c++/17743, for the time being we cannot use
  // the correct, neat implementation :-(
  //
  // template<std::size_t _Len, std::size_t _Align>
  //   struct aligned_storage
  //   { typedef char type[_Len] __attribute__((__aligned__(_Align))); }
  //
  // Temporary workaround, useful for Align up to 32:
  template<std::size_t, std::size_t>
    struct aligned_storage { };

  template<std::size_t _Len>
    struct aligned_storage<_Len, 1>
    {
      union type
      {
	unsigned char __data[_Len];
	char __align __attribute__((__aligned__(1)));
      };
    };

  template<std::size_t _Len>
    struct aligned_storage<_Len, 2>
    {
      union type
      {
	unsigned char __data[_Len];
	char __align __attribute__((__aligned__(2)));
      };
    };

  template<std::size_t _Len>
    struct aligned_storage<_Len, 4>
    {
      union type
      {
	unsigned char __data[_Len];
	char __align __attribute__((__aligned__(4)));
      };
    };

  template<std::size_t _Len>
    struct aligned_storage<_Len, 8>
    {
      union type
      {
	unsigned char __data[_Len];
	char __align __attribute__((__aligned__(8)));
      };
    };

  template<std::size_t _Len>
    struct aligned_storage<_Len, 16>
    {
      union type
      {
	unsigned char __data[_Len];
	char __align __attribute__((__aligned__(16)));
      };
    };

  template<std::size_t _Len>
    struct aligned_storage<_Len, 32>
    {
      union type
      {
	unsigned char __data[_Len];
	char __align __attribute__((__aligned__(32)));
      };
    };

#undef _DEFINE_SPEC_0_HELPER
#undef _DEFINE_SPEC_1_HELPER
#undef _DEFINE_SPEC_2_HELPER
#undef _DEFINE_SPEC
#undef _DEFINE_SPEC_BODY

_GLIBCXX_END_NAMESPACE
}

#endif


code:
// TR1 type_traits -*- C++ -*-

// Copyright (C) 2004, 2005, 2006 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
// terms of the GNU General Public License as published by the
// Free Software Foundation; either version 2, or (at your option)
// any later version.

// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
// GNU General Public License for more details.

// You should have received a copy of the GNU General Public License along
// with this library; see the file COPYING.  If not, write to the Free
// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
// USA.

// As a special exception, you may use this file as part of a free software
// library without restriction.  Specifically, if other files instantiate
// templates or use macros or inline functions from this file, or you compile
// this file and link it with other files to produce an executable, this
// file does not by itself cause the resulting executable to be covered by
// the GNU General Public License.  This exception does not however
// invalidate any other reasons why the executable file might be covered by
// the GNU General Public License.

/** @file tr1/type_traits_fwd.h
 *  This is an internal header file, included by other library headers.
 *  You should not attempt to use it directly.
 */

#ifndef _TYPE_TRAITS_FWD_H
#define _TYPE_TRAITS_FWD_H 1

#include <cstddef>

// namespace std::tr1
namespace std
{
_GLIBCXX_BEGIN_NAMESPACE(tr1)

  /// @brief  helper classes [4.3].
  template<typename _Tp, _Tp __v>
    struct integral_constant;
  typedef integral_constant<bool, true>     true_type;
  typedef integral_constant<bool, false>    false_type;

  /// @brief  primary type categories [4.5.1].
  template<typename _Tp>
    struct is_void;

  template<typename _Tp>
    struct is_integral;

  template<typename _Tp>
    struct is_floating_point;

  template<typename _Tp>
    struct is_array;

  template<typename _Tp>
    struct is_pointer;

  template<typename _Tp>
    struct is_reference;

  template<typename _Tp>
    struct is_member_object_pointer;

  template<typename _Tp>
    struct is_member_function_pointer;

  template<typename _Tp>
    struct is_enum;

  template<typename _Tp>
    struct is_union;

  template<typename _Tp>
    struct is_class;

  template<typename _Tp>
    struct is_function;

  /// @brief  composite type traits [4.5.2].
  template<typename _Tp>
    struct is_arithmetic;

  template<typename _Tp>
    struct is_fundamental;

  template<typename _Tp>
    struct is_object;

  template<typename _Tp>
    struct is_scalar;

  template<typename _Tp>
    struct is_compound;

  template<typename _Tp>
    struct is_member_pointer;

  // Extension.
  template<typename _Tp>
    struct __is_union_or_class;

  /// @brief  type properties [4.5.3].
  template<typename _Tp>
    struct is_const;

  template<typename _Tp>
    struct is_volatile;

  template<typename _Tp>
    struct is_pod;

  template<typename _Tp>
    struct is_empty;

  template<typename _Tp>
    struct is_polymorphic;

  template<typename _Tp>
    struct is_abstract;

  template<typename _Tp>
    struct has_trivial_constructor;

  template<typename _Tp>
    struct has_trivial_copy;

  template<typename _Tp>
    struct has_trivial_assign;

  template<typename _Tp>
    struct has_trivial_destructor;

  template<typename _Tp>
    struct has_nothrow_constructor;

  template<typename _Tp>
    struct has_nothrow_copy;

  template<typename _Tp>
    struct has_nothrow_assign;

  template<typename _Tp>
    struct has_virtual_destructor;

  template<typename _Tp>
    struct is_signed;

  template<typename _Tp>
    struct is_unsigned;

  template<typename _Tp>
    struct alignment_of;

  template<typename _Tp>
    struct rank;

  template<typename _Tp, unsigned _Uint = 0>
    struct extent;

  /// @brief  relationships between types [4.6].
  template<typename _Tp, typename _Up>
    struct is_same;

  template<typename _From, typename _To>
    struct is_convertible;

  template<typename _Base, typename _Derived>
    struct is_base_of;

  /// @brief  const-volatile modifications [4.7.1].
  template<typename _Tp>
    struct remove_const;

  template<typename _Tp>
    struct remove_volatile;

  template<typename _Tp>
    struct remove_cv;

  template<typename _Tp>
    struct add_const;

  template<typename _Tp>
    struct add_volatile;

  template<typename _Tp>
    struct add_cv;

  /// @brief  reference modifications [4.7.2].
  template<typename _Tp>
    struct remove_reference;

  template<typename _Tp>
    struct add_reference;

  /// @brief  array modifications [4.7.3].
  template<typename _Tp>
    struct remove_extent;

  template<typename _Tp>
    struct remove_all_extents;

  /// @brief  pointer modifications [4.7.4].
  template<typename _Tp>
    struct remove_pointer;

  template<typename _Tp>
    struct add_pointer;

  /// @brief  other transformations [4.8].
  template<std::size_t _Len, std::size_t _Align>
    struct aligned_storage;

_GLIBCXX_END_NAMESPACE
}

#endif


code:
// TR1 unordered_map -*- C++ -*-

// Copyright (C) 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
// terms of the GNU General Public License as published by the
// Free Software Foundation; either version 2, or (at your option)
// any later version.

// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
// GNU General Public License for more details.

// You should have received a copy of the GNU General Public License along
// with this library; see the file COPYING.  If not, write to the Free
// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
// USA.

// As a special exception, you may use this file as part of a free software
// library without restriction.  Specifically, if other files instantiate
// templates or use macros or inline functions from this file, or you compile
// this file and link it with other files to produce an executable, this
// file does not by itself cause the resulting executable to be covered by
// the GNU General Public License.  This exception does not however
// invalidate any other reasons why the executable file might be covered by
// the GNU General Public License.

/** @file tr1/unordered_map
 *  This is a TR1 C++ Library header.
 */

#ifndef _TR1_UNORDERED_MAP
#define _TR1_UNORDERED_MAP 1

#include <tr1/hashtable>
#include <tr1/functional_hash.h>

namespace std
{
_GLIBCXX_BEGIN_NAMESPACE(tr1)

  // XXX When we get typedef templates these class definitions
  // will be unnecessary.
  template<class _Key, class _Tp,
	   class _Hash = hash<_Key>,
	   class _Pred = std::equal_to<_Key>,
	   class _Alloc = std::allocator<std::pair<const _Key, _Tp> >,
	   bool __cache_hash_code = false>
    class unordered_map
    : public _Hashtable<_Key, std::pair<const _Key, _Tp>, _Alloc,
			std::_Select1st<std::pair<const _Key, _Tp> >, _Pred,
			_Hash, __detail::_Mod_range_hashing,
			__detail::_Default_ranged_hash,
			__detail::_Prime_rehash_policy,
			__cache_hash_code, false, true>
    {
      typedef _Hashtable<_Key, std::pair<const _Key, _Tp>, _Alloc,
			 std::_Select1st<std::pair<const _Key, _Tp> >, _Pred,
			 _Hash, __detail::_Mod_range_hashing,
			 __detail::_Default_ranged_hash,
			 __detail::_Prime_rehash_policy,
			 __cache_hash_code, false, true>
        _Base;

    public:
      typedef typename _Base::size_type       size_type;
      typedef typename _Base::hasher          hasher;
      typedef typename _Base::key_equal       key_equal;
      typedef typename _Base::allocator_type  allocator_type;

      explicit
      unordered_map(size_type __n = 10,
		    const hasher& __hf = hasher(),
		    const key_equal& __eql = key_equal(),
		    const allocator_type& __a = allocator_type())
      : _Base(__n, __hf, __detail::_Mod_range_hashing(),
	      __detail::_Default_ranged_hash(),
	      __eql, std::_Select1st<std::pair<const _Key, _Tp> >(), __a)
      { }

      template<typename _InputIterator>
        unordered_map(_InputIterator __f, _InputIterator __l,
		      size_type __n = 10,
		      const hasher& __hf = hasher(),
		      const key_equal& __eql = key_equal(),
		      const allocator_type& __a = allocator_type())
	: _Base(__f, __l, __n, __hf, __detail::_Mod_range_hashing(),
		__detail::_Default_ranged_hash(),
		__eql, std::_Select1st<std::pair<const _Key, _Tp> >(), __a)
	{ }
    };

  template<class _Key, class _Tp,
	   class _Hash = hash<_Key>,
	   class _Pred = std::equal_to<_Key>,
	   class _Alloc = std::allocator<std::pair<const _Key, _Tp> >,
	   bool __cache_hash_code = false>
    class unordered_multimap
    : public _Hashtable<_Key, std::pair<const _Key, _Tp>,
			_Alloc,
			std::_Select1st<std::pair<const _Key, _Tp> >, _Pred,
			_Hash, __detail::_Mod_range_hashing,
			__detail::_Default_ranged_hash,
			__detail::_Prime_rehash_policy,
			__cache_hash_code, false, false>
    {
      typedef _Hashtable<_Key, std::pair<const _Key, _Tp>,
			 _Alloc,
			 std::_Select1st<std::pair<const _Key, _Tp> >, _Pred,
			 _Hash, __detail::_Mod_range_hashing,
			 __detail::_Default_ranged_hash,
			 __detail::_Prime_rehash_policy,
			 __cache_hash_code, false, false>
        _Base;

    public:
      typedef typename _Base::size_type       size_type;
      typedef typename _Base::hasher          hasher;
      typedef typename _Base::key_equal       key_equal;
      typedef typename _Base::allocator_type  allocator_type;

      explicit
      unordered_multimap(size_type __n = 10,
			 const hasher& __hf = hasher(),
			 const key_equal& __eql = key_equal(),
			 const allocator_type& __a = allocator_type())
      : _Base(__n, __hf, __detail::_Mod_range_hashing(),
	      __detail::_Default_ranged_hash(),
	      __eql, std::_Select1st<std::pair<const _Key, _Tp> >(), __a)
      { }

      template<typename _InputIterator>
        unordered_multimap(_InputIterator __f, _InputIterator __l,
			   typename _Base::size_type __n = 0,
			   const hasher& __hf = hasher(),
			   const key_equal& __eql = key_equal(),
			   const allocator_type& __a = allocator_type())
	: _Base(__f, __l, __n, __hf, __detail::_Mod_range_hashing(),
		__detail::_Default_ranged_hash(),
		__eql, std::_Select1st<std::pair<const _Key, _Tp> >(), __a)
        { }
    };

  template<class _Key, class _Tp, class _Hash, class _Pred, class _Alloc,
	   bool __cache_hash_code>
    inline void
    swap(unordered_map<_Key, _Tp, _Hash, _Pred,
	 _Alloc, __cache_hash_code>& __x,
	 unordered_map<_Key, _Tp, _Hash, _Pred,
	 _Alloc, __cache_hash_code>& __y)
    { __x.swap(__y); }

  template<class _Key, class _Tp, class _Hash, class _Pred, class _Alloc,
	   bool __cache_hash_code>
    inline void
    swap(unordered_multimap<_Key, _Tp, _Hash, _Pred,
	 _Alloc, __cache_hash_code>& __x,
	 unordered_multimap<_Key, _Tp, _Hash, _Pred,
	 _Alloc, __cache_hash_code>& __y)
    { __x.swap(__y); }

_GLIBCXX_END_NAMESPACE
}

#endif // _TR1_UNORDERED_MAP


code:
// TR1 unordered_set -*- C++ -*-

// Copyright (C) 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
// terms of the GNU General Public License as published by the
// Free Software Foundation; either version 2, or (at your option)
// any later version.

// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
// GNU General Public License for more details.

// You should have received a copy of the GNU General Public License along
// with this library; see the file COPYING.  If not, write to the Free
// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
// USA.

// As a special exception, you may use this file as part of a free software
// library without restriction.  Specifically, if other files instantiate
// templates or use macros or inline functions from this file, or you compile
// this file and link it with other files to produce an executable, this
// file does not by itself cause the resulting executable to be covered by
// the GNU General Public License.  This exception does not however
// invalidate any other reasons why the executable file might be covered by
// the GNU General Public License.

/** @file tr1/unordered_set
 *  This is a TR1 C++ Library header.
 */

#ifndef _TR1_UNORDERED_SET
#define _TR1_UNORDERED_SET 1

#include <tr1/hashtable>
#include <tr1/functional_hash.h>

namespace std
{
_GLIBCXX_BEGIN_NAMESPACE(tr1)

  // XXX When we get typedef templates these class definitions
  // will be unnecessary.
  template<class _Value,
	   class _Hash = hash<_Value>,
	   class _Pred = std::equal_to<_Value>,
	   class _Alloc = std::allocator<_Value>,
	   bool __cache_hash_code = false>
    class unordered_set
    : public _Hashtable<_Value, _Value, _Alloc,
			std::_Identity<_Value>, _Pred,
			_Hash, __detail::_Mod_range_hashing,
			__detail::_Default_ranged_hash,
			__detail::_Prime_rehash_policy,
			__cache_hash_code, true, true>
    {
      typedef _Hashtable<_Value, _Value, _Alloc,
			 std::_Identity<_Value>, _Pred,
			 _Hash, __detail::_Mod_range_hashing,
			 __detail::_Default_ranged_hash,
			 __detail::_Prime_rehash_policy,
			 __cache_hash_code, true, true>
        _Base;

    public:
      typedef typename _Base::size_type       size_type;
      typedef typename _Base::hasher          hasher;
      typedef typename _Base::key_equal       key_equal;
      typedef typename _Base::allocator_type  allocator_type;

      explicit
      unordered_set(size_type __n = 10,
		    const hasher& __hf = hasher(),
		    const key_equal& __eql = key_equal(),
		    const allocator_type& __a = allocator_type())
      : _Base(__n, __hf, __detail::_Mod_range_hashing(),
	      __detail::_Default_ranged_hash(), __eql,
	      std::_Identity<_Value>(), __a)
      { }

      template<typename _InputIterator>
        unordered_set(_InputIterator __f, _InputIterator __l,
		      size_type __n = 10,
		      const hasher& __hf = hasher(),
		      const key_equal& __eql = key_equal(),
		      const allocator_type& __a = allocator_type())
	: _Base(__f, __l, __n, __hf, __detail::_Mod_range_hashing(),
		__detail::_Default_ranged_hash(), __eql,
		std::_Identity<_Value>(), __a)
        { }
    };

  template<class _Value,
	   class _Hash = hash<_Value>,
	   class _Pred = std::equal_to<_Value>,
	   class _Alloc = std::allocator<_Value>,
	   bool __cache_hash_code = false>
    class unordered_multiset
    : public _Hashtable<_Value, _Value, _Alloc,
			std::_Identity<_Value>, _Pred,
			_Hash, __detail::_Mod_range_hashing,
			__detail::_Default_ranged_hash,
			__detail::_Prime_rehash_policy,
			__cache_hash_code, true, false>
    {
      typedef _Hashtable<_Value, _Value, _Alloc,
			 std::_Identity<_Value>, _Pred,
			 _Hash, __detail::_Mod_range_hashing,
			 __detail::_Default_ranged_hash,
			 __detail::_Prime_rehash_policy,
			 __cache_hash_code, true, false>
        _Base;

    public:
      typedef typename _Base::size_type       size_type;
      typedef typename _Base::hasher          hasher;
      typedef typename _Base::key_equal       key_equal;
      typedef typename _Base::allocator_type  allocator_type;

      explicit
      unordered_multiset(size_type __n = 10,
			 const hasher& __hf = hasher(),
			 const key_equal& __eql = key_equal(),
			 const allocator_type& __a = allocator_type())
      : _Base(__n, __hf, __detail::_Mod_range_hashing(),
	      __detail::_Default_ranged_hash(), __eql,
	      std::_Identity<_Value>(), __a)
      { }

      template<typename _InputIterator>
        unordered_multiset(_InputIterator __f, _InputIterator __l,
			   typename _Base::size_type __n = 0,
			   const hasher& __hf = hasher(),
			   const key_equal& __eql = key_equal(),
			   const allocator_type& __a = allocator_type())
	: _Base(__f, __l, __n, __hf, __detail::_Mod_range_hashing(),
		__detail::_Default_ranged_hash(), __eql,
		std::_Identity<_Value>(), __a)
        { }
    };

  template<class _Value, class _Hash, class _Pred, class _Alloc,
	   bool __cache_hash_code>
    inline void
    swap (unordered_set<_Value, _Hash, _Pred,
	  _Alloc, __cache_hash_code>& __x,
	  unordered_set<_Value, _Hash, _Pred,
	  _Alloc, __cache_hash_code>& __y)
    { __x.swap(__y); }

  template<class _Value, class _Hash, class _Pred, class _Alloc,
	   bool __cache_hash_code>
    inline void
    swap(unordered_multiset<_Value, _Hash, _Pred,
	 _Alloc, __cache_hash_code>& __x,
	 unordered_multiset<_Value, _Hash, _Pred,
	 _Alloc, __cache_hash_code>& __y)
    { __x.swap(__y); }

_GLIBCXX_END_NAMESPACE
}

#endif // _TR1_UNORDERED_SET


code:
// TR1 utility -*- C++ -*-

// 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
// terms of the GNU General Public License as published by the
// Free Software Foundation; either version 2, or (at your option)
// any later version.

// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
// GNU General Public License for more details.

// You should have received a copy of the GNU General Public License along
// with this library; see the file COPYING.  If not, write to the Free
// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
// USA.

// As a special exception, you may use this file as part of a free software
// library without restriction.  Specifically, if other files instantiate
// templates or use macros or inline functions from this file, or you compile
// this file and link it with other files to produce an executable, this
// file does not by itself cause the resulting executable to be covered by
// the GNU General Public License.  This exception does not however
// invalidate any other reasons why the executable file might be covered by
// the GNU General Public License.

/** @file tr1/utility
 *  This is a TR1 C++ Library header.
 */

#ifndef _TR1_UTILITY
#define _TR1_UTILITY 1

#include "../utility"

namespace std
{
_GLIBCXX_BEGIN_NAMESPACE(tr1)

  template<class _Tp> class tuple_size;
  template<int _Int, class _Tp> class tuple_element;

   // Various functions which give std::pair a tuple-like interface.
  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<class _Tp1, class _Tp2>
    struct tuple_element<1, std::pair<_Tp1, _Tp2> >
    { typedef _Tp2 type; };

  template<int _Int> struct __pair_get;

  template<>
    struct __pair_get<0>
    {
      template<typename _Tp1, typename _Tp2>
      static _Tp1& __get(std::pair<_Tp1, _Tp2>& __pair)
      { return __pair.first; }

      template<typename _Tp1, typename _Tp2>
      static const _Tp1& __const_get(const std::pair<_Tp1, _Tp2>& __pair)
      { return __pair.first; }
    };

  template<>
    struct __pair_get<1>
    {
      template<typename _Tp1, typename _Tp2>
      static _Tp2& __get(std::pair<_Tp1, _Tp2>& __pair)
      { return __pair.second; }

      template<typename _Tp1, typename _Tp2>
      static const _Tp2& __const_get(const std::pair<_Tp1, _Tp2>& __pair)
      { return __pair.second; }
    };

   template<int _Int, class _Tp1, class _Tp2>
     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>
     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


code:
// TR1 wchar.h -*- C++ -*-

// Copyright (C) 2006 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
// terms of the GNU General Public License as published by the
// Free Software Foundation; either version 2, or (at your option)
// any later version.

// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
// GNU General Public License for more details.

// You should have received a copy of the GNU General Public License along
// with this library; see the file COPYING.  If not, write to the Free
// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
// USA.

// As a special exception, you may use this file as part of a free software
// library without restriction.  Specifically, if other files instantiate
// templates or use macros or inline functions from this file, or you compile
// this file and link it with other files to produce an executable, this
// file does not by itself cause the resulting executable to be covered by
// the GNU General Public License.  This exception does not however
// invalidate any other reasons why the executable file might be covered by
// the GNU General Public License.

/** @file tr1/wchar.h
 *  This is a TR1 C++ Library header.
 */

#ifndef _TR1_WCHAR_H
#define _TR1_WCHAR_H 1

#include <tr1/cwchar>

#endif


code:
// TR1 wctype.h -*- C++ -*-

// Copyright (C) 2006 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
// terms of the GNU General Public License as published by the
// Free Software Foundation; either version 2, or (at your option)
// any later version.

// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
// GNU General Public License for more details.

// You should have received a copy of the GNU General Public License along
// with this library; see the file COPYING.  If not, write to the Free
// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
// USA.

// As a special exception, you may use this file as part of a free software
// library without restriction.  Specifically, if other files instantiate
// templates or use macros or inline functions from this file, or you compile
// this file and link it with other files to produce an executable, this
// file does not by itself cause the resulting executable to be covered by
// the GNU General Public License.  This exception does not however
// invalidate any other reasons why the executable file might be covered by
// the GNU General Public License.

/** @file tr1/wctype.h
 *  This is a TR1 C++ Library header.
 */

#ifndef _TR1_WCTYPE_H
#define _TR1_WCTYPE_H 1

#include <tr1/cwctype>

#endif


code:
// RTTI support for -*- C++ -*-
// Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
// 2003, 2004, 2005, 2006, 2007
// Free Software Foundation
//
// This file is part of GCC.
//
// GCC is free software; you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation; either version 2, or (at your option)
// any later version.
//
// GCC is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with GCC; see the file COPYING.  If not, write to
// the Free Software Foundation, 51 Franklin Street, Fifth Floor,
// Boston, MA 02110-1301, USA.

// As a special exception, you may use this file as part of a free software
// library without restriction.  Specifically, if other files instantiate
// templates or use macros or inline functions from this file, or you compile
// this file and link it with other files to produce an executable, this
// file does not by itself cause the resulting executable to be covered by
// the GNU General Public License.  This exception does not however
// invalidate any other reasons why the executable file might be covered by
// the GNU General Public License.

/** @file typeinfo
 *  This is a Standard C++ Library header.
 */

#ifndef _TYPEINFO
#define _TYPEINFO

#include <exception>

#pragma GCC visibility push(default)

extern "C++" {

namespace __cxxabiv1
{
  class __class_type_info;
} // namespace __cxxabiv1

#ifndef __GXX_MERGED_TYPEINFO_NAMES
  #if !__GXX_WEAK__
    // If weak symbols are not supported, typeinfo names are not merged.
    #define __GXX_MERGED_TYPEINFO_NAMES 0
  #else
    // On platforms that support weak symbols, typeinfo names are merged.
    #define __GXX_MERGED_TYPEINFO_NAMES 1
  #endif
#endif

namespace std
{
  /**
   *  @brief  Part of RTTI.
   *
   *  The @c type_info class describes type information generated by
   *  an implementation.
  */
  class type_info
  {
  public:
    /** Destructor first. Being the first non-inline virtual function, this
     *  controls in which translation unit the vtable is emitted. The
     *  compiler makes use of that information to know where to emit
     *  the runtime-mandated type_info structures in the new-abi.  */
    virtual ~type_info();

    /** Returns an @e implementation-defined byte string; this is not
     *  portable between compilers!  */
    const char* name() const
    { return __name; }

#if !__GXX_MERGED_TYPEINFO_NAMES
    bool before(const type_info& __arg) const;

    // In old abi, or when weak symbols are not supported, there can
    // be multiple instances of a type_info object for one
    // type. Uniqueness must use the _name value, not object address.
    bool operator==(const type_info& __arg) const;
#else
    /** Returns true if @c *this precedes @c __arg in the implementation's
     *  collation order.  */
    // In new abi we can rely on type_info's NTBS being unique,
    // and therefore address comparisons are sufficient.
    bool before(const type_info& __arg) const
    { return __name < __arg.__name; }

    bool operator==(const type_info& __arg) const
    { return __name == __arg.__name; }
#endif
    bool operator!=(const type_info& __arg) const
    { return !operator==(__arg); }

    // Try and catch a thrown type. Store an adjusted pointer to the
    // caught type in THR_OBJ. If THR_TYPE is not a pointer type, then
    // THR_OBJ points to the thrown object. If THR_TYPE is a pointer
    // type, then THR_OBJ is the pointer itself. OUTER indicates the
    // number of outer pointers, and whether they were const
    // qualified.
    virtual bool __do_catch(const type_info *__thr_type, void **__thr_obj,
			    unsigned __outer) const;

    // Internally used during catch matching
    virtual bool __do_upcast(const __cxxabiv1::__class_type_info *__target,
			     void **__obj_ptr) const;

   // Return true if this is a pointer type of some kind
    virtual bool __is_pointer_p() const;

    // Return true if this is a function type
    virtual bool __is_function_p() const;

  protected:
    const char *__name;

    explicit type_info(const char *__n): __name(__n) { }

  private:
    /// Assigning type_info is not supported.
    type_info& operator=(const type_info&);
    type_info(const type_info&);
  };

  /**
   *  @brief  Thrown during incorrect typecasting.
   *
   *  If you attempt an invalid @c dynamic_cast expression, an instance of
   *  this class (or something derived from this class) is thrown.  */
  class bad_cast : public exception
  {
  public:
    bad_cast() throw() { }

    // This declaration is not useless:
    // http://gcc.gnu.org/onlinedocs/gcc-3.0.2/gcc_6.html#SEC118
    virtual ~bad_cast() throw();

    // See comment in eh_exception.cc.
    virtual const char* what() const throw();
  };

  /** If you use a NULL pointer in a @c typeid expression, this is thrown.  */
  class bad_typeid : public exception
  {
  public:
    bad_typeid () throw() { }

    // This declaration is not useless:
    // http://gcc.gnu.org/onlinedocs/gcc-3.0.2/gcc_6.html#SEC118
    virtual ~bad_typeid() throw();

    // See comment in eh_exception.cc.
    virtual const char* what() const throw();
  };
} // namespace std

#pragma GCC visibility pop

} // extern "C++"
#endif


code:
// <utility> -*- C++ -*-

// Copyright (C) 2001, 2002 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
// terms of the GNU General Public License as published by the
// Free Software Foundation; either version 2, or (at your option)
// any later version.

// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
// GNU General Public License for more details.

// You should have received a copy of the GNU General Public License along
// with this library; see the file COPYING.  If not, write to the Free
// Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
// USA.

// As a special exception, you may use this file as part of a free software
// library without restriction.  Specifically, if other files instantiate
// templates or use macros or inline functions from this file, or you compile
// this file and link it with other files to produce an executable, this
// file does not by itself cause the resulting executable to be covered by
// the GNU General Public License.  This exception does not however
// invalidate any other reasons why the executable file might be covered by
// the GNU General Public License.

/*
 *
 * Copyright (c) 1994
 * Hewlett-Packard Company
 *
 * Permission to use, copy, modify, distribute and sell this software
 * and its documentation for any purpose is hereby granted without fee,
 * provided that the above copyright notice appear in all copies and
 * that both that copyright notice and this permission notice appear
 * in supporting documentation.  Hewlett-Packard Company makes no
 * representations about the suitability of this software for any
 * purpose.  It is provided "as is" without express or implied warranty.
 *
 *
 * Copyright (c) 1996,1997
 * Silicon Graphics Computer Systems, Inc.
 *
 * Permission to use, copy, modify, distribute and sell this software
 * and its documentation for any purpose is hereby granted without fee,
 * provided that the above copyright notice appear in all copies and
 * that both that copyright notice and this permission notice appear
 * in supporting documentation.  Silicon Graphics makes no
 * representations about the suitability of this software for any
 * purpose.  It is provided "as is" without express or implied warranty.
 */

/** @file include/utility
 *  This is a Standard C++ Library header.
 */

#ifndef _GLIBCXX_UTILITY
#define _GLIBCXX_UTILITY 1

#pragma GCC system_header

#include <bits/c++config.h>
#include <bits/stl_relops.h>
#include <bits/stl_pair.h>

#endif /* _GLIBCXX_UTILITY */