From: Douglas Gregor Date: Sat, 10 Mar 2007 02:04:13 +0000 (+0000) Subject: Makefile.in: Regenerate. X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=9eeea7612d055f00ce21fd1442411c838d82b452;p=platform%2Fupstream%2Fgcc.git Makefile.in: Regenerate. 2007-03-09 Douglas Gregor * include/Makefile.in: Regenerate. * include/tr1/mu_iterate.h: Remove. * include/tr1/tuple (_Tuple_impl): New. (tuple): Make variadic, re-implement as shell over _Tuple_impl. (0-element tuple): Basis case. (2-element tuple): Handle pair methods. (__get_helper): Remove. (tuple_element): Reimplement with variadic templates. (tuple_size): Ditto. (get): Ditto. (operator==): Use variadic templates in the signature. (operator<): Ditto. (operator!=): Ditto. (operator>): Ditto. (operator<=): Ditto. (operator>=): Ditto. (__stripped_tuple_type): Remove; we've inlined its behavior. (make_tuple): Reimplement with variadic templates. (tie): Ditto. * include/tr1/tuple_iterate.h: Remove. * include/tr1/bind_repeat.h: Remove. * include/tr1/ref_wrap_iterate.h: Remove. * include/tr1/bind_iterate.h: Remove. * include/tr1/functional (_Weak_result_type): Add variadic partial specializations. (result_of): Ditto. (__invoke): Reimplement using variadic templates. (reference_wrapper): Reimplement operator() with variadic templates. (_Maybe_unary_or_binary_function): New. (_Mem_fn): Implement for member function pointers using variadic templates. (placeholders): Define 30 placeholders. (_Index_tuple): New. (_Build_index_tuple): New. (_No_tuple_element): New. (_Safe_tuple_element_impl): New. (_Safe_tuple_element): New. (_Mu): Reimplement with variadic templates, use _Safe_tuple_element instead of tuple_element. (_Bind): Reimplement with variadic templates and tuples. (_Bind_result): Ditto. (bind): Reimplement with variadic templates. (_Function_handler): Ditto. (function): Ditto. * include/tr1/functional_iterate.h: Remove. * include/tr1/repeat.h: Remove. * include/Makefile.am: Don't install removed headers. From-SVN: r122790 --- diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog index c4b2fb0..6402706 100644 --- a/libstdc++-v3/ChangeLog +++ b/libstdc++-v3/ChangeLog @@ -1,3 +1,54 @@ +2007-03-09 Douglas Gregor + + * include/Makefile.in: Regenerate. + * include/tr1/mu_iterate.h: Remove. + * include/tr1/tuple (_Tuple_impl): New. + (tuple): Make variadic, re-implement as shell over _Tuple_impl. + (0-element tuple): Basis case. + (2-element tuple): Handle pair methods. + (__get_helper): Remove. + (tuple_element): Reimplement with variadic templates. + (tuple_size): Ditto. + (get): Ditto. + (operator==): Use variadic templates in the signature. + (operator<): Ditto. + (operator!=): Ditto. + (operator>): Ditto. + (operator<=): Ditto. + (operator>=): Ditto. + (__stripped_tuple_type): Remove; we've inlined its behavior. + (make_tuple): Reimplement with variadic templates. + (tie): Ditto. + * include/tr1/tuple_iterate.h: Remove. + * include/tr1/bind_repeat.h: Remove. + * include/tr1/ref_wrap_iterate.h: Remove. + * include/tr1/bind_iterate.h: Remove. + * include/tr1/functional (_Weak_result_type): Add variadic + partial specializations. + (result_of): Ditto. + (__invoke): Reimplement using variadic templates. + (reference_wrapper): Reimplement operator() with variadic + templates. + (_Maybe_unary_or_binary_function): New. + (_Mem_fn): Implement for member function pointers using variadic + templates. + (placeholders): Define 30 placeholders. + (_Index_tuple): New. + (_Build_index_tuple): New. + (_No_tuple_element): New. + (_Safe_tuple_element_impl): New. + (_Safe_tuple_element): New. + (_Mu): Reimplement with variadic templates, use + _Safe_tuple_element instead of tuple_element. + (_Bind): Reimplement with variadic templates and tuples. + (_Bind_result): Ditto. + (bind): Reimplement with variadic templates. + (_Function_handler): Ditto. + (function): Ditto. + * include/tr1/functional_iterate.h: Remove. + * include/tr1/repeat.h: Remove. + * include/Makefile.am: Don't install removed headers. + 2007-03-06 Paolo Carlini PR libstdc++/28080 (partial) diff --git a/libstdc++-v3/include/Makefile.am b/libstdc++-v3/include/Makefile.am index 0d24903..b5cbc99 100644 --- a/libstdc++-v3/include/Makefile.am +++ b/libstdc++-v3/include/Makefile.am @@ -532,8 +532,6 @@ tr1_srcdir = ${glibcxx_srcdir}/include/tr1 tr1_builddir = ./tr1 tr1_headers = \ ${tr1_srcdir}/array \ - ${tr1_srcdir}/bind_repeat.h \ - ${tr1_srcdir}/bind_iterate.h \ ${tr1_srcdir}/boost_shared_ptr.h \ ${tr1_srcdir}/ccomplex \ ${tr1_srcdir}/cctype \ @@ -559,20 +557,16 @@ tr1_headers = \ ${tr1_srcdir}/float.h \ ${tr1_srcdir}/functional \ ${tr1_srcdir}/functional_hash.h \ - ${tr1_srcdir}/functional_iterate.h \ ${tr1_srcdir}/hashtable \ ${tr1_srcdir}/hashtable_policy.h \ ${tr1_srcdir}/inttypes.h \ ${tr1_srcdir}/limits.h \ ${tr1_srcdir}/math.h \ ${tr1_srcdir}/memory \ - ${tr1_srcdir}/mu_iterate.h \ ${tr1_srcdir}/random \ ${tr1_srcdir}/random.tcc \ ${tr1_srcdir}/ref_fwd.h \ - ${tr1_srcdir}/ref_wrap_iterate.h \ ${tr1_srcdir}/regex \ - ${tr1_srcdir}/repeat.h \ ${tr1_srcdir}/stdarg.h \ ${tr1_srcdir}/stdbool.h \ ${tr1_srcdir}/stdint.h \ @@ -580,8 +574,6 @@ tr1_headers = \ ${tr1_srcdir}/stdlib.h \ ${tr1_srcdir}/tgmath.h \ ${tr1_srcdir}/tuple \ - ${tr1_srcdir}/tuple_defs.h \ - ${tr1_srcdir}/tuple_iterate.h \ ${tr1_srcdir}/type_traits \ ${tr1_srcdir}/type_traits_fwd.h \ ${tr1_srcdir}/unordered_set \ diff --git a/libstdc++-v3/include/Makefile.in b/libstdc++-v3/include/Makefile.in index fb3ca7d..93f4d97 100644 --- a/libstdc++-v3/include/Makefile.in +++ b/libstdc++-v3/include/Makefile.in @@ -762,8 +762,6 @@ tr1_srcdir = ${glibcxx_srcdir}/include/tr1 tr1_builddir = ./tr1 tr1_headers = \ ${tr1_srcdir}/array \ - ${tr1_srcdir}/bind_repeat.h \ - ${tr1_srcdir}/bind_iterate.h \ ${tr1_srcdir}/boost_shared_ptr.h \ ${tr1_srcdir}/ccomplex \ ${tr1_srcdir}/cctype \ @@ -789,20 +787,16 @@ tr1_headers = \ ${tr1_srcdir}/float.h \ ${tr1_srcdir}/functional \ ${tr1_srcdir}/functional_hash.h \ - ${tr1_srcdir}/functional_iterate.h \ ${tr1_srcdir}/hashtable \ ${tr1_srcdir}/hashtable_policy.h \ ${tr1_srcdir}/inttypes.h \ ${tr1_srcdir}/limits.h \ ${tr1_srcdir}/math.h \ ${tr1_srcdir}/memory \ - ${tr1_srcdir}/mu_iterate.h \ ${tr1_srcdir}/random \ ${tr1_srcdir}/random.tcc \ ${tr1_srcdir}/ref_fwd.h \ - ${tr1_srcdir}/ref_wrap_iterate.h \ ${tr1_srcdir}/regex \ - ${tr1_srcdir}/repeat.h \ ${tr1_srcdir}/stdarg.h \ ${tr1_srcdir}/stdbool.h \ ${tr1_srcdir}/stdint.h \ @@ -810,8 +804,6 @@ tr1_headers = \ ${tr1_srcdir}/stdlib.h \ ${tr1_srcdir}/tgmath.h \ ${tr1_srcdir}/tuple \ - ${tr1_srcdir}/tuple_defs.h \ - ${tr1_srcdir}/tuple_iterate.h \ ${tr1_srcdir}/type_traits \ ${tr1_srcdir}/type_traits_fwd.h \ ${tr1_srcdir}/unordered_set \ diff --git a/libstdc++-v3/include/tr1/bind_iterate.h b/libstdc++-v3/include/tr1/bind_iterate.h deleted file mode 100644 index 3de49a7..0000000 --- a/libstdc++-v3/include/tr1/bind_iterate.h +++ /dev/null @@ -1,78 +0,0 @@ -// TR1 functional -*- C++ -*- - -// Copyright (C) 2005 Free Software Foundation, Inc. -// Written by Douglas Gregor -// -// 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/bind_iterate.h - * This is an internal header file, included by other library headers. - * You should not attempt to use it directly. - */ - -#if _GLIBCXX_BIND_NUM_ARGS > 0 -template<_GLIBCXX_BIND_TEMPLATE_PARAMS> -#endif -#ifdef _GLIBCXX_BIND_HAS_RESULT_TYPE -result_type -#else -typename result_of<_Functor(_GLIBCXX_BIND_V_TEMPLATE_ARGS())>::type -#endif -operator()(_GLIBCXX_BIND_PARAMS) -{ return _M_f(_GLIBCXX_BIND_V_ARGS); } - -#if _GLIBCXX_BIND_NUM_ARGS > 0 -template<_GLIBCXX_BIND_TEMPLATE_PARAMS> -#endif -#ifdef _GLIBCXX_BIND_HAS_RESULT_TYPE -result_type -#else -typename result_of::type -#endif -operator()(_GLIBCXX_BIND_PARAMS) const -{ return _M_f(_GLIBCXX_BIND_V_ARGS); } - -#if _GLIBCXX_BIND_NUM_ARGS > 0 -template<_GLIBCXX_BIND_TEMPLATE_PARAMS> -#endif -#ifdef _GLIBCXX_BIND_HAS_RESULT_TYPE -result_type -#else -typename result_of::type -#endif -operator()(_GLIBCXX_BIND_PARAMS) volatile -{ return _M_f(_GLIBCXX_BIND_V_ARGS); } - -#if _GLIBCXX_BIND_NUM_ARGS > 0 -template<_GLIBCXX_BIND_TEMPLATE_PARAMS> -#endif -#ifdef _GLIBCXX_BIND_HAS_RESULT_TYPE -result_type -#else -typename result_of::type -#endif -operator()(_GLIBCXX_BIND_PARAMS) const volatile -{ return _M_f(_GLIBCXX_BIND_V_ARGS); } diff --git a/libstdc++-v3/include/tr1/bind_repeat.h b/libstdc++-v3/include/tr1/bind_repeat.h deleted file mode 100644 index 8ec29a2..0000000 --- a/libstdc++-v3/include/tr1/bind_repeat.h +++ /dev/null @@ -1,192 +0,0 @@ -// TR1 code repetition for bind -*- C++ -*- - -// Copyright (C) 2005 Free Software Foundation, Inc. -// Written by Douglas Gregor -// -// 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/bind_repeat.h - * This is an internal header file, included by other library headers. - * You should not attempt to use it directly. - */ - -#ifndef _GLIBCXX_BIND_REPEAT_HEADER -# error Internal error: _GLIBCXX_BIND_REPEAT_HEADER must be set -#endif /* _GLIBCXX_BIND_REPEAT_HEADER */ - -#define _GLIBCXX_BIND_NUM_ARGS 0 -#define _GLIBCXX_BIND_COMMA -#define _GLIBCXX_BIND_TEMPLATE_PARAMS -#define _GLIBCXX_BIND_TEMPLATE_ARGS -#define _GLIBCXX_BIND_PARAMS -#define _GLIBCXX_BIND_ARGS -# include _GLIBCXX_BIND_REPEAT_HEADER -#undef _GLIBCXX_BIND_ARGS -#undef _GLIBCXX_BIND_PARAMS -#undef _GLIBCXX_BIND_TEMPLATE_ARGS -#undef _GLIBCXX_BIND_TEMPLATE_PARAMS -#undef _GLIBCXX_BIND_COMMA -#undef _GLIBCXX_BIND_NUM_ARGS - -#define _GLIBCXX_BIND_NUM_ARGS 1 -#define _GLIBCXX_BIND_COMMA , -#define _GLIBCXX_BIND_TEMPLATE_PARAMS typename _U1 -#define _GLIBCXX_BIND_TEMPLATE_ARGS _U1 -#define _GLIBCXX_BIND_PARAMS _U1& __u1 -#define _GLIBCXX_BIND_ARGS __u1 -#include _GLIBCXX_BIND_REPEAT_HEADER -#undef _GLIBCXX_BIND_ARGS -#undef _GLIBCXX_BIND_PARAMS -#undef _GLIBCXX_BIND_TEMPLATE_ARGS -#undef _GLIBCXX_BIND_TEMPLATE_PARAMS -#undef _GLIBCXX_BIND_COMMA -#undef _GLIBCXX_BIND_NUM_ARGS -#define _GLIBCXX_BIND_NUM_ARGS 2 -#define _GLIBCXX_BIND_COMMA , -#define _GLIBCXX_BIND_TEMPLATE_PARAMS typename _U1, typename _U2 -#define _GLIBCXX_BIND_TEMPLATE_ARGS _U1, _U2 -#define _GLIBCXX_BIND_PARAMS _U1& __u1, _U2& __u2 -#define _GLIBCXX_BIND_ARGS __u1, __u2 -#include _GLIBCXX_BIND_REPEAT_HEADER -#undef _GLIBCXX_BIND_ARGS -#undef _GLIBCXX_BIND_PARAMS -#undef _GLIBCXX_BIND_TEMPLATE_ARGS -#undef _GLIBCXX_BIND_TEMPLATE_PARAMS -#undef _GLIBCXX_BIND_COMMA -#undef _GLIBCXX_BIND_NUM_ARGS - -#define _GLIBCXX_BIND_NUM_ARGS 3 -#define _GLIBCXX_BIND_COMMA , -#define _GLIBCXX_BIND_TEMPLATE_PARAMS typename _U1, typename _U2, typename _U3 -#define _GLIBCXX_BIND_TEMPLATE_ARGS _U1, _U2, _U3 -#define _GLIBCXX_BIND_PARAMS _U1& __u1, _U2& __u2, _U3& __u3 -#define _GLIBCXX_BIND_ARGS __u1, __u2, __u3 -#include _GLIBCXX_BIND_REPEAT_HEADER -#undef _GLIBCXX_BIND_ARGS -#undef _GLIBCXX_BIND_PARAMS -#undef _GLIBCXX_BIND_TEMPLATE_ARGS -#undef _GLIBCXX_BIND_TEMPLATE_PARAMS -#undef _GLIBCXX_BIND_COMMA -#undef _GLIBCXX_BIND_NUM_ARGS - -#define _GLIBCXX_BIND_NUM_ARGS 4 -#define _GLIBCXX_BIND_COMMA , -#define _GLIBCXX_BIND_TEMPLATE_PARAMS typename _U1, typename _U2, typename _U3, typename _U4 -#define _GLIBCXX_BIND_TEMPLATE_ARGS _U1, _U2, _U3, _U4 -#define _GLIBCXX_BIND_PARAMS _U1& __u1, _U2& __u2, _U3& __u3, _U4& __u4 -#define _GLIBCXX_BIND_ARGS __u1, __u2, __u3, __u4 -#include _GLIBCXX_BIND_REPEAT_HEADER -#undef _GLIBCXX_BIND_ARGS -#undef _GLIBCXX_BIND_PARAMS -#undef _GLIBCXX_BIND_TEMPLATE_ARGS -#undef _GLIBCXX_BIND_TEMPLATE_PARAMS -#undef _GLIBCXX_BIND_COMMA -#undef _GLIBCXX_BIND_NUM_ARGS - -#define _GLIBCXX_BIND_NUM_ARGS 5 -#define _GLIBCXX_BIND_COMMA , -#define _GLIBCXX_BIND_TEMPLATE_PARAMS typename _U1, typename _U2, typename _U3, typename _U4, typename _U5 -#define _GLIBCXX_BIND_TEMPLATE_ARGS _U1, _U2, _U3, _U4, _U5 -#define _GLIBCXX_BIND_PARAMS _U1& __u1, _U2& __u2, _U3& __u3, _U4& __u4, _U5& __u5 -#define _GLIBCXX_BIND_ARGS __u1, __u2, __u3, __u4, __u5 -#include _GLIBCXX_BIND_REPEAT_HEADER -#undef _GLIBCXX_BIND_ARGS -#undef _GLIBCXX_BIND_PARAMS -#undef _GLIBCXX_BIND_TEMPLATE_ARGS -#undef _GLIBCXX_BIND_TEMPLATE_PARAMS -#undef _GLIBCXX_BIND_COMMA -#undef _GLIBCXX_BIND_NUM_ARGS - -#define _GLIBCXX_BIND_NUM_ARGS 6 -#define _GLIBCXX_BIND_COMMA , -#define _GLIBCXX_BIND_TEMPLATE_PARAMS typename _U1, typename _U2, typename _U3, typename _U4, typename _U5, typename _U6 -#define _GLIBCXX_BIND_TEMPLATE_ARGS _U1, _U2, _U3, _U4, _U5, _U6 -#define _GLIBCXX_BIND_PARAMS _U1& __u1, _U2& __u2, _U3& __u3, _U4& __u4, _U5& __u5, _U6& __u6 -#define _GLIBCXX_BIND_ARGS __u1, __u2, __u3, __u4, __u5, __u6 -#include _GLIBCXX_BIND_REPEAT_HEADER -#undef _GLIBCXX_BIND_ARGS -#undef _GLIBCXX_BIND_PARAMS -#undef _GLIBCXX_BIND_TEMPLATE_ARGS -#undef _GLIBCXX_BIND_TEMPLATE_PARAMS -#undef _GLIBCXX_BIND_COMMA -#undef _GLIBCXX_BIND_NUM_ARGS - -#define _GLIBCXX_BIND_NUM_ARGS 7 -#define _GLIBCXX_BIND_COMMA , -#define _GLIBCXX_BIND_TEMPLATE_PARAMS typename _U1, typename _U2, typename _U3, typename _U4, typename _U5, typename _U6, typename _U7 -#define _GLIBCXX_BIND_TEMPLATE_ARGS _U1, _U2, _U3, _U4, _U5, _U6, _U7 -#define _GLIBCXX_BIND_PARAMS _U1& __u1, _U2& __u2, _U3& __u3, _U4& __u4, _U5& __u5, _U6& __u6, _U7& __u7 -#define _GLIBCXX_BIND_ARGS __u1, __u2, __u3, __u4, __u5, __u6, __u7 -#include _GLIBCXX_BIND_REPEAT_HEADER -#undef _GLIBCXX_BIND_ARGS -#undef _GLIBCXX_BIND_PARAMS -#undef _GLIBCXX_BIND_TEMPLATE_ARGS -#undef _GLIBCXX_BIND_TEMPLATE_PARAMS -#undef _GLIBCXX_BIND_COMMA -#undef _GLIBCXX_BIND_NUM_ARGS - -#define _GLIBCXX_BIND_NUM_ARGS 8 -#define _GLIBCXX_BIND_COMMA , -#define _GLIBCXX_BIND_TEMPLATE_PARAMS typename _U1, typename _U2, typename _U3, typename _U4, typename _U5, typename _U6, typename _U7, typename _U8 -#define _GLIBCXX_BIND_TEMPLATE_ARGS _U1, _U2, _U3, _U4, _U5, _U6, _U7, _U8 -#define _GLIBCXX_BIND_PARAMS _U1& __u1, _U2& __u2, _U3& __u3, _U4& __u4, _U5& __u5, _U6& __u6, _U7& __u7, _U8& __u8 -#define _GLIBCXX_BIND_ARGS __u1, __u2, __u3, __u4, __u5, __u6, __u7, __u8 -#include _GLIBCXX_BIND_REPEAT_HEADER -#undef _GLIBCXX_BIND_ARGS -#undef _GLIBCXX_BIND_PARAMS -#undef _GLIBCXX_BIND_TEMPLATE_ARGS -#undef _GLIBCXX_BIND_TEMPLATE_PARAMS -#undef _GLIBCXX_BIND_COMMA -#undef _GLIBCXX_BIND_NUM_ARGS - -#define _GLIBCXX_BIND_NUM_ARGS 9 -#define _GLIBCXX_BIND_COMMA , -#define _GLIBCXX_BIND_TEMPLATE_PARAMS typename _U1, typename _U2, typename _U3, typename _U4, typename _U5, typename _U6, typename _U7, typename _U8, typename _U9 -#define _GLIBCXX_BIND_TEMPLATE_ARGS _U1, _U2, _U3, _U4, _U5, _U6, _U7, _U8, _U9 -#define _GLIBCXX_BIND_PARAMS _U1& __u1, _U2& __u2, _U3& __u3, _U4& __u4, _U5& __u5, _U6& __u6, _U7& __u7, _U8& __u8, _U9& __u9 -#define _GLIBCXX_BIND_ARGS __u1, __u2, __u3, __u4, __u5, __u6, __u7, __u8, __u9 -#include _GLIBCXX_BIND_REPEAT_HEADER -#undef _GLIBCXX_BIND_ARGS -#undef _GLIBCXX_BIND_PARAMS -#undef _GLIBCXX_BIND_TEMPLATE_ARGS -#undef _GLIBCXX_BIND_TEMPLATE_PARAMS -#undef _GLIBCXX_BIND_COMMA -#undef _GLIBCXX_BIND_NUM_ARGS - -#define _GLIBCXX_BIND_NUM_ARGS 10 -#define _GLIBCXX_BIND_COMMA , -#define _GLIBCXX_BIND_TEMPLATE_PARAMS typename _U1, typename _U2, typename _U3, typename _U4, typename _U5, typename _U6, typename _U7, typename _U8, typename _U9, typename _U10 -#define _GLIBCXX_BIND_TEMPLATE_ARGS _U1, _U2, _U3, _U4, _U5, _U6, _U7, _U8, _U9, _U10 -#define _GLIBCXX_BIND_PARAMS _U1& __u1, _U2& __u2, _U3& __u3, _U4& __u4, _U5& __u5, _U6& __u6, _U7& __u7, _U8& __u8, _U9& __u9, _U10& __u10 -#define _GLIBCXX_BIND_ARGS __u1, __u2, __u3, __u4, __u5, __u6, __u7, __u8, __u9, __u10 -#include _GLIBCXX_BIND_REPEAT_HEADER -#undef _GLIBCXX_BIND_ARGS -#undef _GLIBCXX_BIND_PARAMS -#undef _GLIBCXX_BIND_TEMPLATE_ARGS -#undef _GLIBCXX_BIND_TEMPLATE_PARAMS -#undef _GLIBCXX_BIND_COMMA -#undef _GLIBCXX_BIND_NUM_ARGS - diff --git a/libstdc++-v3/include/tr1/functional b/libstdc++-v3/include/tr1/functional index 736b770..897d487 100644 --- a/libstdc++-v3/include/tr1/functional +++ b/libstdc++-v3/include/tr1/functional @@ -111,6 +111,83 @@ _GLIBCXX_BEGIN_NAMESPACE(_GLIBCXX_TR1) }; /** + * @if maint + * Retrieve the result type for a function type. + * @endif + */ + template + struct _Weak_result_type_impl<_Res(_ArgTypes...)> + { + typedef _Res result_type; + }; + + /** + * @if maint + * Retrieve the result type for a function reference. + * @endif + */ + template + struct _Weak_result_type_impl<_Res(&)(_ArgTypes...)> + { + typedef _Res result_type; + }; + + /** + * @if maint + * Retrieve the result type for a function pointer. + * @endif + */ + template + struct _Weak_result_type_impl<_Res(*)(_ArgTypes...)> + { + typedef _Res result_type; + }; + + /** + * @if maint + * Retrieve result type for a member function pointer. + * @endif maint + */ + template + struct _Weak_result_type_impl<_Res (_Class::*)(_ArgTypes...)> + { + typedef _Res result_type; + }; + + /** + * @if maint + * Retrieve result type for a const member function pointer. + * @endif maint + */ + template + struct _Weak_result_type_impl<_Res (_Class::*)(_ArgTypes...) const> + { + typedef _Res result_type; + }; + + /** + * @if maint + * Retrieve result type for a volatile member function pointer. + * @endif maint + */ + template + struct _Weak_result_type_impl<_Res (_Class::*)(_ArgTypes...) volatile> + { + typedef _Res result_type; + }; + + /** + * @if maint + * Retrieve result type for a const volatile member function pointer. + * @endif maint + */ + template + struct _Weak_result_type_impl<_Res (_Class::*)(_ArgTypes...)const volatile> + { + typedef _Res result_type; + }; + + /** * @if maint * Strip top-level cv-qualifiers from the function object and let * _Weak_result_type_impl perform the real work. @@ -145,6 +222,56 @@ _GLIBCXX_BEGIN_NAMESPACE(_GLIBCXX_TR1) }; /** + * @if maint + * Determine whether we can determine a result type from @c Functor + * alone. + * @endif + */ + template + class result_of<_Functor(_ArgTypes...)> + : public _Result_of_impl< + _Has_result_type<_Weak_result_type<_Functor> >::value, + _Functor(_ArgTypes...)> + { + }; + + /** + * @if maint + * We already know the result type for @c Functor; use it. + * @endif + */ + template + struct _Result_of_impl + { + typedef typename _Weak_result_type<_Functor>::result_type type; + }; + + /** + * @if maint + * We need to compute the result type for this invocation the hard + * way. + * @endif + */ + template + struct _Result_of_impl + { + typedef typename _Functor + ::template result<_Functor(_ArgTypes...)>::type type; + }; + + /** + * @if maint + * It is unsafe to access ::result when there are zero arguments, so we + * return @c void instead. + * @endif + */ + template + struct _Result_of_impl + { + typedef void type; + }; + + /** * @if maint * Determines if the type _Tp derives from unary_function. * @endif @@ -202,6 +329,51 @@ _GLIBCXX_BEGIN_NAMESPACE(_GLIBCXX_TR1) }; /** + * @if maint + * Invoke a function object, which may be either a member pointer or a + * function object. The first parameter will tell which. + * @endif + */ + template + inline + typename __gnu_cxx::__enable_if< + (!is_member_pointer<_Functor>::value + && !is_function<_Functor>::value + && !is_function::type>::value), + typename result_of<_Functor(_Args...)>::type + >::__type + __invoke(_Functor& __f, _Args&... __args) + { + return __f(__args...); + } + + template + inline + typename __gnu_cxx::__enable_if< + (is_member_pointer<_Functor>::value + && !is_function<_Functor>::value + && !is_function::type>::value), + typename result_of<_Functor(_Args...)>::type + >::__type + __invoke(_Functor& __f, _Args&... __args) + { + return mem_fn(__f)(__args...); + } + + // To pick up function references (that will become function pointers) + template + inline + typename __gnu_cxx::__enable_if< + (is_pointer<_Functor>::value + && is_function::type>::value), + typename result_of<_Functor(_Args...)>::type + >::__type + __invoke(_Functor __f, _Args&... __args) + { + return __f(__args...); + } + + /** * @if maint * Knowing which of unary_function and binary_function _Tp derives * from, derives from the same and ensures that reference_wrapper @@ -366,9 +538,12 @@ _GLIBCXX_BEGIN_NAMESPACE(_GLIBCXX_TR1) get() const { return *_M_data; } -#define _GLIBCXX_REPEAT_HEADER -#include -#undef _GLIBCXX_REPEAT_HEADER + template + typename result_of<_M_func_type(_Args...)>::type + operator()(_Args&... __args) const + { + return __invoke(get(), __args...); + } }; @@ -406,6 +581,216 @@ _GLIBCXX_BEGIN_NAMESPACE(_GLIBCXX_TR1) typedef _Tp& type; }; + /** + * @if maint + * Derives from @c unary_function or @c binary_function, or perhaps + * nothing, depending on the number of arguments provided. The + * primary template is the basis case, which derives nothing. + * @endif maint + */ + template + struct _Maybe_unary_or_binary_function { }; + + /** + * @if maint + * Derives from @c unary_function, as appropriate. + * @endif + */ + template + struct _Maybe_unary_or_binary_function<_Res, _T1> + : std::unary_function<_T1, _Res> { }; + + /** + * @if maint + * Derives from @c binary_function, as appropriate. + * @endif + */ + template + struct _Maybe_unary_or_binary_function<_Res, _T1, _T2> + : std::binary_function<_T1, _T2, _Res> { }; + + /** + * @if maint + * Implementation of @c mem_fn for member function pointers. + * @endif + */ + template + class _Mem_fn<_Res (_Class::*)(_ArgTypes...)> + : public _Maybe_unary_or_binary_function<_Res, _Class*, _ArgTypes...> + { + typedef _Res (_Class::*_Functor)(_ArgTypes...); + + template + _Res + _M_call(_Tp& __object, const volatile _Class *, + _ArgTypes... __args) const + { return (__object.*__pmf)(__args...); } + + template + _Res + _M_call(_Tp& __ptr, const volatile void *, _ArgTypes... __args) const + { return ((*__ptr).*__pmf)(__args...); } + + public: + typedef _Res result_type; + + explicit _Mem_fn(_Functor __pmf) : __pmf(__pmf) { } + + // Handle objects + _Res operator()(_Class& __object, _ArgTypes... __args) const + { return (__object.*__pmf)(__args...); } + + // Handle pointers + _Res operator()(_Class* __object, _ArgTypes... __args) const + { return (__object->*__pmf)(__args...); } + + // Handle smart pointers, references and pointers to derived + template + _Res operator()(_Tp& __object, _ArgTypes... __args) const + { return _M_call(__object, &__object, __args...); } + + private: + _Functor __pmf; + }; + + /** + * @if maint + * Implementation of @c mem_fn for const member function pointers. + * @endif + */ + template + class _Mem_fn<_Res (_Class::*)(_ArgTypes...) const> + : public _Maybe_unary_or_binary_function<_Res, const _Class*, + _ArgTypes...> + { + typedef _Res (_Class::*_Functor)(_ArgTypes...) const; + + template + _Res + _M_call(_Tp& __object, const volatile _Class *, + _ArgTypes... __args) const + { return (__object.*__pmf)(__args...); } + + template + _Res + _M_call(_Tp& __ptr, const volatile void *, _ArgTypes... __args) const + { return ((*__ptr).*__pmf)(__args...); } + + public: + typedef _Res result_type; + + explicit _Mem_fn(_Functor __pmf) : __pmf(__pmf) { } + + // Handle objects + _Res operator()(const _Class& __object, _ArgTypes... __args) const + { return (__object.*__pmf)(__args...); } + + // Handle pointers + _Res operator()(const _Class* __object, _ArgTypes... __args) const + { return (__object->*__pmf)(__args...); } + + // Handle smart pointers, references and pointers to derived + template + _Res operator()(_Tp& __object, _ArgTypes... __args) const + { return _M_call(__object, &__object, __args...); } + + private: + _Functor __pmf; + }; + + /** + * @if maint + * Implementation of @c mem_fn for volatile member function pointers. + * @endif + */ + template + class _Mem_fn<_Res (_Class::*)(_ArgTypes...) volatile> + : public _Maybe_unary_or_binary_function<_Res, volatile _Class*, + _ArgTypes...> + { + typedef _Res (_Class::*_Functor)(_ArgTypes...) volatile; + + template + _Res + _M_call(_Tp& __object, const volatile _Class *, + _ArgTypes... __args) const + { return (__object.*__pmf)(__args...); } + + template + _Res + _M_call(_Tp& __ptr, const volatile void *, _ArgTypes... __args) const + { return ((*__ptr).*__pmf)(__args...); } + + public: + typedef _Res result_type; + + explicit _Mem_fn(_Functor __pmf) : __pmf(__pmf) { } + + // Handle objects + _Res operator()(volatile _Class& __object, _ArgTypes... __args) const + { return (__object.*__pmf)(__args...); } + + // Handle pointers + _Res operator()(volatile _Class* __object, _ArgTypes... __args) const + { return (__object->*__pmf)(__args...); } + + // Handle smart pointers, references and pointers to derived + template + _Res operator()(_Tp& __object, _ArgTypes... __args) const + { return _M_call(__object, &__object, __args...); } + + private: + _Functor __pmf; + }; + + /** + * @if maint + * Implementation of @c mem_fn for const volatile member function pointers. + * @endif + */ + template + class _Mem_fn<_Res (_Class::*)(_ArgTypes...) const volatile> + : public _Maybe_unary_or_binary_function<_Res, const volatile _Class*, + _ArgTypes...> + { + typedef _Res (_Class::*_Functor)(_ArgTypes...) const volatile; + + template + _Res + _M_call(_Tp& __object, const volatile _Class *, + _ArgTypes... __args) const + { return (__object.*__pmf)(__args...); } + + template + _Res + _M_call(_Tp& __ptr, const volatile void *, _ArgTypes... __args) const + { return ((*__ptr).*__pmf)(__args...); } + + public: + typedef _Res result_type; + + explicit _Mem_fn(_Functor __pmf) : __pmf(__pmf) { } + + // Handle objects + _Res + operator()(const volatile _Class& __object, _ArgTypes... __args) const + { return (__object.*__pmf)(__args...); } + + // Handle pointers + _Res + operator()(const volatile _Class* __object, _ArgTypes... __args) const + { return (__object->*__pmf)(__args...); } + + // Handle smart pointers, references and pointers to derived + template + _Res operator()(_Tp& __object, _ArgTypes... __args) const + { return _M_call(__object, &__object, __args...); } + + private: + _Functor __pmf; + }; + + template class _Mem_fn<_Res _Class::*> { @@ -537,6 +922,41 @@ _GLIBCXX_BEGIN_NAMESPACE(_GLIBCXX_TR1) */ template struct _Placeholder { }; + // Define a large number of placeholders. There is no way to + // simplify this with variadic templates, because we're introducing + // unique names for each. + namespace placeholders { namespace { + _Placeholder<1> _1; + _Placeholder<2> _2; + _Placeholder<3> _3; + _Placeholder<4> _4; + _Placeholder<5> _5; + _Placeholder<6> _6; + _Placeholder<7> _7; + _Placeholder<8> _8; + _Placeholder<9> _9; + _Placeholder<10> _10; + _Placeholder<11> _11; + _Placeholder<12> _12; + _Placeholder<13> _13; + _Placeholder<14> _14; + _Placeholder<15> _15; + _Placeholder<16> _16; + _Placeholder<17> _17; + _Placeholder<18> _18; + _Placeholder<19> _19; + _Placeholder<20> _20; + _Placeholder<21> _21; + _Placeholder<22> _22; + _Placeholder<23> _23; + _Placeholder<24> _24; + _Placeholder<25> _25; + _Placeholder<26> _26; + _Placeholder<27> _27; + _Placeholder<28> _28; + _Placeholder<29> _29; + } } + /** * @if maint * Partial specialization of is_placeholder that provides the placeholder @@ -551,6 +971,79 @@ _GLIBCXX_BEGIN_NAMESPACE(_GLIBCXX_TR1) const int is_placeholder<_Placeholder<_Num> >::value; /** + * @if maint + * Stores a tuple of indices. Used by bind() to extract the elements + * in a tuple. + * @endif + */ + template + struct _Index_tuple { }; + + /** + * @if maint + * Builds an _Index_tuple<0, 1, 2, ..., _Num-1>. + * @endif + */ + template > + struct _Build_index_tuple; + + template + struct _Build_index_tuple<_Num, _Index_tuple<_Indexes...> > + : _Build_index_tuple<_Num - 1, + _Index_tuple<_Indexes..., sizeof...(_Indexes)> > + { + }; + + template + struct _Build_index_tuple<0, _Index_tuple<_Indexes...> > + { + typedef _Index_tuple<_Indexes...> __type; + }; + + /** + * @if maint + * Used by _Safe_tuple_element to indicate that there is no tuple + * element at this position. + * @endif + */ + struct _No_tuple_element; + + /** + * @if maint + * Implementation helper for _Safe_tuple_element. This primary + * template handles the case where it is safe to use @c + * tuple_element. + * @endif + */ + template + struct _Safe_tuple_element_impl + : tuple_element<__i, _Tuple> { }; + + /** + * @if maint + * Implementation helper for _Safe_tuple_element. This partial + * specialization handles the case where it is not safe to use @c + * tuple_element. We just return @c _No_tuple_element. + * @endif + */ + template + struct _Safe_tuple_element_impl<__i, _Tuple, false> + { + typedef _No_tuple_element type; + }; + + /** + * Like tuple_element, but returns @c _No_tuple_element when + * tuple_element would return an error. + */ + template + struct _Safe_tuple_element + : _Safe_tuple_element_impl<__i, _Tuple, + (__i >= 0 && __i < tuple_size<_Tuple>::value)> + { + }; + + /** * @if maint * Maps an argument to bind() into an actual argument to the bound * function object [TR1 3.6.3/5]. Only the first parameter should @@ -603,9 +1096,33 @@ _GLIBCXX_BEGIN_NAMESPACE(_GLIBCXX_TR1) public: template class result; -#define _GLIBCXX_REPEAT_HEADER -# include -#undef _GLIBCXX_REPEAT_HEADER + // Determine the result type when we pass the arguments along. This + // involves passing along the cv-qualifiers placed on _Mu and + // unwrapping the argument bundle. + template + class result<_CVMu(_CVArg, tuple<_Args...>)> + : public result_of<_CVArg(_Args...)> { }; + + template + typename result_of<_CVArg(_Args...)>::type + operator()(_CVArg& __arg, const tuple<_Args...>& __tuple) + const volatile + { + // Construct an index tuple and forward to __call + typedef typename _Build_index_tuple::__type _Indexes; + return this->__call(__arg, __tuple, _Indexes()); + } + + private: + // Invokes the underlying function object __arg by unpacking all + // of the arguments in the tuple. + template + typename result_of<_CVArg(_Args...)>::type + __call(_CVArg& __arg, const tuple<_Args...>& __tuple, + const _Index_tuple<_Indexes...>&) const volatile + { + return __arg(_GLIBCXX_TR1::get<_Indexes>(__tuple)...); + } }; /** @@ -627,8 +1144,8 @@ _GLIBCXX_BEGIN_NAMESPACE(_GLIBCXX_TR1) // Add a reference, if it hasn't already been done for us. // This allows us to be a little bit sloppy in constructing // the tuple that we pass to result_of<...>. - typedef typename tuple_element<(is_placeholder<_Arg>::value - 1), - _Tuple>::type __base_type; + typedef typename _Safe_tuple_element<(is_placeholder<_Arg>::value - 1), + _Tuple>::type __base_type; public: typedef typename add_reference<__base_type>::type type; @@ -700,23 +1217,226 @@ _GLIBCXX_BEGIN_NAMESPACE(_GLIBCXX_TR1) * Type of the function object returned from bind(). * @endif */ - template - struct _Bind; + template + struct _Bind; + + template + class _Bind<_Functor(_Bound_args...)> + : public _Weak_result_type<_Functor> + { + typedef _Bind __self_type; + typedef typename _Build_index_tuple::__type + _Bound_indexes; + + _Functor _M_f; + tuple<_Bound_args...> _M_bound_args; + + // Call unqualified + template + typename result_of< + _Functor(typename result_of<_Mu<_Bound_args> + (_Bound_args, tuple<_Args...>)>::type...) + >::type + __call(const tuple<_Args...>& __args, _Index_tuple<_Indexes...>) + { + return _M_f(_Mu<_Bound_args>() + (_GLIBCXX_TR1::get<_Indexes>(_M_bound_args), __args)...); + } + + // Call as const + template + typename result_of< + const _Functor(typename result_of<_Mu<_Bound_args> + (const _Bound_args, tuple<_Args...>) + >::type...)>::type + __call(const tuple<_Args...>& __args, _Index_tuple<_Indexes...>) const + { + return _M_f(_Mu<_Bound_args>() + (_GLIBCXX_TR1::get<_Indexes>(_M_bound_args), __args)...); + } + + // Call as volatile + template + typename result_of< + volatile _Functor(typename result_of<_Mu<_Bound_args> + (volatile _Bound_args, tuple<_Args...>) + >::type...)>::type + __call(const tuple<_Args...>& __args, + _Index_tuple<_Indexes...>) volatile + { + return _M_f(_Mu<_Bound_args>() + (_GLIBCXX_TR1::get<_Indexes>(_M_bound_args), __args)...); + } + + // Call as const volatile + template + typename result_of< + const volatile _Functor(typename result_of<_Mu<_Bound_args> + (const volatile _Bound_args, + tuple<_Args...>) + >::type...)>::type + __call(const tuple<_Args...>& __args, + _Index_tuple<_Indexes...>) const volatile + { + return _M_f(_Mu<_Bound_args>() + (_GLIBCXX_TR1::get<_Indexes>(_M_bound_args), __args)...); + } + + public: + explicit _Bind(_Functor __f, _Bound_args... __bound_args) + : _M_f(__f), _M_bound_args(__bound_args...) { } + + // Call unqualified + template + typename result_of< + _Functor(typename result_of<_Mu<_Bound_args> + (_Bound_args, tuple<_Args...>)>::type...) + >::type + operator()(_Args&... __args) + { + return this->__call(_GLIBCXX_TR1::tie(__args...), _Bound_indexes()); + } + + // Call as const + template + typename result_of< + const _Functor(typename result_of<_Mu<_Bound_args> + (const _Bound_args, tuple<_Args...>)>::type...) + >::type + operator()(_Args&... __args) const + { + return this->__call(_GLIBCXX_TR1::tie(__args...), _Bound_indexes()); + } + + + // Call as volatile + template + typename result_of< + volatile _Functor(typename result_of<_Mu<_Bound_args> + (volatile _Bound_args, tuple<_Args...>)>::type...) + >::type + operator()(_Args&... __args) volatile + { + return this->__call(_GLIBCXX_TR1::tie(__args...), _Bound_indexes()); + } + + + // Call as const volatile + template + typename result_of< + const volatile _Functor(typename result_of<_Mu<_Bound_args> + (const volatile _Bound_args, + tuple<_Args...>)>::type...) + >::type + operator()(_Args&... __args) const volatile + { + return this->__call(_GLIBCXX_TR1::tie(__args...), _Bound_indexes()); + } + }; /** * @if maint * Type of the function object returned from bind(). * @endif */ - template - struct _Bind_result; + template + struct _Bind_result; + + template + class _Bind_result<_Result, _Functor(_Bound_args...)> + { + typedef _Bind_result __self_type; + typedef typename _Build_index_tuple::__type + _Bound_indexes; + + _Functor _M_f; + tuple<_Bound_args...> _M_bound_args; + + // Call unqualified + template + _Result + __call(const tuple<_Args...>& __args, _Index_tuple<_Indexes...>) + { + return _M_f(_Mu<_Bound_args>() + (_GLIBCXX_TR1::get<_Indexes>(_M_bound_args), __args)...); + } + + // Call as const + template + _Result + __call(const tuple<_Args...>& __args, _Index_tuple<_Indexes...>) const + { + return _M_f(_Mu<_Bound_args>() + (_GLIBCXX_TR1::get<_Indexes>(_M_bound_args), __args)...); + } + + // Call as volatile + template + _Result + __call(const tuple<_Args...>& __args, + _Index_tuple<_Indexes...>) volatile + { + return _M_f(_Mu<_Bound_args>() + (_GLIBCXX_TR1::get<_Indexes>(_M_bound_args), __args)...); + } + + // Call as const volatile + template + _Result + __call(const tuple<_Args...>& __args, + _Index_tuple<_Indexes...>) const volatile + { + return _M_f(_Mu<_Bound_args>() + (_GLIBCXX_TR1::get<_Indexes>(_M_bound_args), __args)...); + } + + public: + typedef _Result result_type; + + explicit _Bind_result(_Functor __f, _Bound_args... __bound_args) + : _M_f(__f), _M_bound_args(__bound_args...) { } + + // Call unqualified + template + result_type + operator()(_Args&... __args) + { + return this->__call(_GLIBCXX_TR1::tie(__args...), _Bound_indexes()); + } + + // Call as const + template + result_type + operator()(_Args&... __args) const + { + return this->__call(_GLIBCXX_TR1::tie(__args...), _Bound_indexes()); + } + + + // Call as volatile + template + result_type + operator()(_Args&... __args) volatile + { + return this->__call(_GLIBCXX_TR1::tie(__args...), _Bound_indexes()); + } + + + // Call as const volatile + template + result_type + operator()(_Args&... __args) const volatile + { + return this->__call(_GLIBCXX_TR1::tie(__args...), _Bound_indexes()); + } + }; /** * @if maint * Class template _Bind is always a bind expression. * @endif */ - template + template struct is_bind_expression<_Bind<_Signature> > { static const bool value = true; }; @@ -728,9 +1448,36 @@ _GLIBCXX_BEGIN_NAMESPACE(_GLIBCXX_TR1) * Class template _Bind_result is always a bind expression. * @endif */ - template - struct is_bind_expression<_Bind_result<_Result, _Signature> > - { static const bool value = true; }; + template + struct is_bind_expression<_Bind_result<_Result, _Signature> > + { + static const bool value = true; + }; + + template + inline + _Bind::type(_ArgTypes...)> + bind(_Functor __f, _ArgTypes... __args) + { + typedef _Maybe_wrap_member_pointer<_Functor> __maybe_type; + typedef typename __maybe_type::type __functor_type; + typedef _Bind<__functor_type(_ArgTypes...)> __result_type; + return __result_type(__maybe_type::__do_wrap(__f), __args...); + } + + template + inline + _Bind_result<_Result, + typename _Maybe_wrap_member_pointer<_Functor>::type + (_ArgTypes...)> + bind(_Functor __f, _ArgTypes... __args) + { + typedef _Maybe_wrap_member_pointer<_Functor> __maybe_type; + typedef typename __maybe_type::type __functor_type; + typedef _Bind_result<_Result, __functor_type(_ArgTypes...)> + __result_type; + return __result_type(__maybe_type::__do_wrap(__f), __args...); + } template const bool is_bind_expression<_Bind_result<_Result, _Signature> >::value; @@ -829,13 +1576,9 @@ _GLIBCXX_BEGIN_NAMESPACE(_GLIBCXX_TR1) __callable_functor(_Member _Class::* const &__p) { return mem_fn(__p); } - template - class _Function_handler; - template class function; - /** * @if maint * Base class of all polymorphic function object wrappers. @@ -1026,6 +1769,434 @@ _GLIBCXX_BEGIN_NAMESPACE(_GLIBCXX_TR1) _Manager_type _M_manager; }; + template + class _Function_handler; + + template + class _Function_handler<_Res(_ArgTypes...), _Functor> + : public _Function_base::_Base_manager<_Functor> + { + typedef _Function_base::_Base_manager<_Functor> _Base; + + public: + static _Res _M_invoke(const _Any_data& __functor, _ArgTypes... __args) + { + return (*_Base::_M_get_pointer(__functor))(__args...); + } + }; + + template + class _Function_handler + : public _Function_base::_Base_manager<_Functor> + { + typedef _Function_base::_Base_manager<_Functor> _Base; + + public: + static void _M_invoke(const _Any_data& __functor, _ArgTypes... __args) + { + (*_Base::_M_get_pointer(__functor))(__args...); + } + }; + + template + class _Function_handler<_Res(_ArgTypes...), reference_wrapper<_Functor> > + : public _Function_base::_Ref_manager<_Functor> + { + typedef _Function_base::_Ref_manager<_Functor> _Base; + + public: + static _Res _M_invoke(const _Any_data& __functor, _ArgTypes... __args) + { + return + __callable_functor(**_Base::_M_get_pointer(__functor))(__args...); + } + }; + + template + class _Function_handler > + : public _Function_base::_Ref_manager<_Functor> + { + typedef _Function_base::_Ref_manager<_Functor> _Base; + + public: + static void _M_invoke(const _Any_data& __functor, _ArgTypes... __args) + { + __callable_functor(**_Base::_M_get_pointer(__functor))(__args...); + } + }; + + template + class _Function_handler<_Res(_ArgTypes...), _Member _Class::*> + : public _Function_handler + { + typedef _Function_handler + _Base; + + public: + static _Res _M_invoke(const _Any_data& __functor, _ArgTypes... __args) + { + return _GLIBCXX_TR1::mem_fn(_Base::_M_get_pointer(__functor)->__value)(__args...); + } + }; + + template + class _Function_handler + : public _Function_base::_Base_manager< + _Simple_type_wrapper< _Member _Class::* > > + { + typedef _Member _Class::* _Functor; + typedef _Simple_type_wrapper< _Functor > _Wrapper; + typedef _Function_base::_Base_manager<_Wrapper> _Base; + + public: + static bool + _M_manager(_Any_data& __dest, const _Any_data& __source, + _Manager_operation __op) + { + switch (__op) { + case __get_type_info: + __dest._M_access() = &typeid(_Functor); + break; + + case __get_functor_ptr: + __dest._M_access<_Functor*>() = + &_Base::_M_get_pointer(__source)->__value; + break; + + default: + _Base::_M_manager(__dest, __source, __op); + } + return false; + } + + static void _M_invoke(const _Any_data& __functor, _ArgTypes... __args) + { + _GLIBCXX_TR1::mem_fn(_Base::_M_get_pointer(__functor)->__value)(__args...); + } + }; + + template + class function<_Res(_ArgTypes...)> + : public _Maybe_unary_or_binary_function<_Res, _ArgTypes...>, + private _Function_base + { + /** + * @if maint + * This class is used to implement the safe_bool idiom. + * @endif + */ + struct _Hidden_type + { + _Hidden_type* _M_bool; + }; + + /** + * @if maint + * This typedef is used to implement the safe_bool idiom. + * @endif + */ + typedef _Hidden_type* _Hidden_type::* _Safe_bool; + + typedef _Res _Signature_type(_ArgTypes...); + + struct _Useless {}; + + public: + typedef _Res result_type; + + // [3.7.2.1] construct/copy/destroy + + /** + * @brief Default construct creates an empty function call wrapper. + * @post @c !(bool)*this + */ + function() : _Function_base() { } + + /** + * @brief Default construct creates an empty function call wrapper. + * @post @c !(bool)*this + */ + function(_M_clear_type*) : _Function_base() { } + + /** + * @brief %Function copy constructor. + * @param x A %function object with identical call signature. + * @pre @c (bool)*this == (bool)x + * + * The newly-created %function contains a copy of the target of @a + * x (if it has one). + */ + function(const function& __x); + + /** + * @brief Builds a %function that targets a copy of the incoming + * function object. + * @param f A %function object that is callable with parameters of + * type @c T1, @c T2, ..., @c TN and returns a value convertible + * to @c Res. + * + * The newly-created %function object will target a copy of @a + * f. If @a f is @c reference_wrapper, then this function + * object will contain a reference to the function object @c + * f.get(). If @a f is a NULL function pointer or NULL + * pointer-to-member, the newly-created object will be empty. + * + * If @a f is a non-NULL function pointer or an object of type @c + * reference_wrapper, this function will not throw. + */ + template + function(_Functor __f, + typename __gnu_cxx::__enable_if< + !is_integral<_Functor>::value, _Useless>::__type + = _Useless()); + + /** + * @brief %Function assignment operator. + * @param x A %function with identical call signature. + * @post @c (bool)*this == (bool)x + * @returns @c *this + * + * The target of @a x is copied to @c *this. If @a x has no + * target, then @c *this will be empty. + * + * If @a x targets a function pointer or a reference to a function + * object, then this operation will not throw an exception. + */ + function& operator=(const function& __x) + { + function(__x).swap(*this); + return *this; + } + + /** + * @brief %Function assignment to zero. + * @post @c !(bool)*this + * @returns @c *this + * + * The target of @a *this is deallocated, leaving it empty. + */ + function& operator=(_M_clear_type*) + { + if (_M_manager) { + _M_manager(_M_functor, _M_functor, __destroy_functor); + _M_manager = 0; + _M_invoker = 0; + } + return *this; + } + + /** + * @brief %Function assignment to a new target. + * @param f A %function object that is callable with parameters of + * type @c T1, @c T2, ..., @c TN and returns a value convertible + * to @c Res. + * @return @c *this + * + * This %function object wrapper will target a copy of @a + * f. If @a f is @c reference_wrapper, then this function + * object will contain a reference to the function object @c + * f.get(). If @a f is a NULL function pointer or NULL + * pointer-to-member, @c this object will be empty. + * + * If @a f is a non-NULL function pointer or an object of type @c + * reference_wrapper, this function will not throw. + */ + template + typename __gnu_cxx::__enable_if::value, + function&>::__type + operator=(_Functor __f) + { + function(__f).swap(*this); + return *this; + } + + // [3.7.2.2] function modifiers + + /** + * @brief Swap the targets of two %function objects. + * @param f A %function with identical call signature. + * + * Swap the targets of @c this function object and @a f. This + * function will not throw an exception. + */ + void swap(function& __x) + { + _Any_data __old_functor = _M_functor; + _M_functor = __x._M_functor; + __x._M_functor = __old_functor; + _Manager_type __old_manager = _M_manager; + _M_manager = __x._M_manager; + __x._M_manager = __old_manager; + _Invoker_type __old_invoker = _M_invoker; + _M_invoker = __x._M_invoker; + __x._M_invoker = __old_invoker; + } + + // [3.7.2.3] function capacity + + /** + * @brief Determine if the %function wrapper has a target. + * + * @return @c true when this %function object contains a target, + * or @c false when it is empty. + * + * This function will not throw an exception. + */ + operator _Safe_bool() const + { + if (_M_empty()) + { + return 0; + } + else + { + return &_Hidden_type::_M_bool; + } + } + + // [3.7.2.4] function invocation + + /** + * @brief Invokes the function targeted by @c *this. + * @returns the result of the target. + * @throws bad_function_call when @c !(bool)*this + * + * The function call operator invokes the target function object + * stored by @c this. + */ + _Res operator()(_ArgTypes... __args) const; + + // [3.7.2.5] function target access + /** + * @brief Determine the type of the target of this function object + * wrapper. + * + * @returns the type identifier of the target function object, or + * @c typeid(void) if @c !(bool)*this. + * + * This function will not throw an exception. + */ + const type_info& target_type() const; + + /** + * @brief Access the stored target function object. + * + * @return Returns a pointer to the stored target function object, + * if @c typeid(Functor).equals(target_type()); otherwise, a NULL + * pointer. + * + * This function will not throw an exception. + */ + template _Functor* target(); + + /** + * @overload + */ + template const _Functor* target() const; + + private: + // [3.7.2.6] undefined operators + template + void operator==(const function<_Function>&) const; + template + void operator!=(const function<_Function>&) const; + + typedef _Res (*_Invoker_type)(const _Any_data&, _ArgTypes...); + _Invoker_type _M_invoker; + }; + + template + function<_Res(_ArgTypes...)>::function(const function& __x) + : _Function_base() + { + if (__x) { + _M_invoker = __x._M_invoker; + _M_manager = __x._M_manager; + __x._M_manager(_M_functor, __x._M_functor, __clone_functor); + } + } + + template + template + function<_Res(_ArgTypes...)> + ::function(_Functor __f, + typename __gnu_cxx::__enable_if< + !is_integral<_Functor>::value, _Useless>::__type) + : _Function_base() + { + typedef _Function_handler<_Signature_type, _Functor> _My_handler; + if (_My_handler::_M_not_empty_function(__f)) { + _M_invoker = &_My_handler::_M_invoke; + _M_manager = &_My_handler::_M_manager; + _My_handler::_M_init_functor(_M_functor, __f); + } + } + + template + _Res function<_Res(_ArgTypes...)>::operator()(_ArgTypes... __args) const + { + if (_M_empty()) + { +#if __EXCEPTIONS + throw bad_function_call(); +#else + std::abort(); +#endif + } + return _M_invoker(_M_functor, __args...); + } + + template + const type_info& function<_Res(_ArgTypes...)>::target_type() const + { + if (_M_manager) + { + _Any_data __typeinfo_result; + _M_manager(__typeinfo_result, _M_functor, __get_type_info); + return *__typeinfo_result._M_access(); + } + else + { + return typeid(void); + } + } + + template + template + _Functor* function<_Res(_ArgTypes...)>::target() + { + if (typeid(_Functor) == target_type() && _M_manager) + { + _Any_data __ptr; + if (_M_manager(__ptr, _M_functor, __get_functor_ptr) + && !is_const<_Functor>::value) + return 0; + else + return __ptr._M_access<_Functor*>(); + } + else + { + return 0; + } + } + + template + template + const _Functor* function<_Res(_ArgTypes...)>::target() const + { + if (typeid(_Functor) == target_type() && _M_manager) + { + _Any_data __ptr; + _M_manager(__ptr, _M_functor, __get_functor_ptr); + return __ptr._M_access(); + } + else + { + return 0; + } + } + // [3.7.2.7] null pointer comparisons /** @@ -1093,16 +2264,6 @@ _GLIBCXX_BEGIN_NAMESPACE(_GLIBCXX_TR1) _GLIBCXX_END_NAMESPACE } -#define _GLIBCXX_JOIN(X,Y) _GLIBCXX_JOIN2( X , Y ) -#define _GLIBCXX_JOIN2(X,Y) _GLIBCXX_JOIN3(X,Y) -#define _GLIBCXX_JOIN3(X,Y) X##Y -#define _GLIBCXX_REPEAT_HEADER -#include -#undef _GLIBCXX_REPEAT_HEADER -#undef _GLIBCXX_JOIN3 -#undef _GLIBCXX_JOIN2 -#undef _GLIBCXX_JOIN - #include #endif diff --git a/libstdc++-v3/include/tr1/functional_iterate.h b/libstdc++-v3/include/tr1/functional_iterate.h deleted file mode 100644 index 3772e15..0000000 --- a/libstdc++-v3/include/tr1/functional_iterate.h +++ /dev/null @@ -1,922 +0,0 @@ -// TR1 functional -*- C++ -*- - -// Copyright (C) 2005, 2006, 2007 Free Software Foundation, Inc. -// Written by Douglas Gregor -// -// 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/functional_iterate.h - * This is an internal header file, included by other library headers. - * You should not attempt to use it directly. - */ - -namespace std -{ -_GLIBCXX_BEGIN_NAMESPACE(_GLIBCXX_TR1) - -template - struct _Weak_result_type_impl<_Res(_GLIBCXX_TEMPLATE_ARGS)> - { - typedef _Res result_type; - }; - -template - struct _Weak_result_type_impl<_Res (&)(_GLIBCXX_TEMPLATE_ARGS)> - { - typedef _Res result_type; - }; - -template - struct _Weak_result_type_impl<_Res (*)(_GLIBCXX_TEMPLATE_ARGS)> - { - typedef _Res result_type; - }; - -#if _GLIBCXX_NUM_ARGS > 0 -template - struct _Weak_result_type_impl< - _Res (_Class::*)(_GLIBCXX_TEMPLATE_ARGS_SHIFTED)> - { - typedef _Res result_type; - }; - -template - struct _Weak_result_type_impl< - _Res (_Class::*)(_GLIBCXX_TEMPLATE_ARGS_SHIFTED) const> - { - typedef _Res result_type; - }; - -template - struct _Weak_result_type_impl< - _Res (_Class::*)(_GLIBCXX_TEMPLATE_ARGS_SHIFTED) volatile> - { - typedef _Res result_type; - }; - -template - struct _Weak_result_type_impl< - _Res (_Class::*)(_GLIBCXX_TEMPLATE_ARGS_SHIFTED) const volatile> - { - typedef _Res result_type; - }; -#endif - -template - class result_of<_Functor(_GLIBCXX_TEMPLATE_ARGS)> - : public _Result_of_impl< - _Has_result_type<_Weak_result_type<_Functor> >::value, - _Functor(_GLIBCXX_TEMPLATE_ARGS)> - { }; - -template - struct _Result_of_impl - { - typedef typename _Weak_result_type<_Functor>::result_type type; - }; - -template - struct _Result_of_impl - { -#if _GLIBCXX_NUM_ARGS > 0 - typedef typename _Functor - ::template result<_Functor(_GLIBCXX_TEMPLATE_ARGS)>::type type; -#else - typedef void type; -#endif - }; - -/** - * @if maint - * Invoke a function object, which may be either a member pointer or a - * function object. The first parameter will tell which. - * @endif - */ -template - inline - typename __gnu_cxx::__enable_if<(!is_member_pointer<_Functor>::value - && !is_function<_Functor>::value - && !is_function::type>::value), - typename result_of<_Functor(_GLIBCXX_TEMPLATE_ARGS)>::type>::__type - __invoke(_Functor& __f _GLIBCXX_COMMA _GLIBCXX_REF_PARAMS) - { - return __f(_GLIBCXX_ARGS); - } - -#if _GLIBCXX_NUM_ARGS > 0 -template - inline - typename __gnu_cxx::__enable_if<(is_member_pointer<_Functor>::value - && !is_function<_Functor>::value - && !is_function::type>::value), - typename result_of<_Functor(_GLIBCXX_TEMPLATE_ARGS)>::type - >::__type - __invoke(_Functor& __f _GLIBCXX_COMMA _GLIBCXX_REF_PARAMS) - { - return mem_fn(__f)(_GLIBCXX_ARGS); - } -#endif - -// To pick up function references (that will become function pointers) -template - inline - typename __gnu_cxx::__enable_if<(is_pointer<_Functor>::value - && is_function::type>::value), - typename result_of<_Functor(_GLIBCXX_TEMPLATE_ARGS)>::type - >::__type - __invoke(_Functor __f _GLIBCXX_COMMA _GLIBCXX_REF_PARAMS) - { - return __f(_GLIBCXX_ARGS); - } - -/** - * @if maint - * Implementation of reference_wrapper::operator() - * @endif -*/ -#if _GLIBCXX_NUM_ARGS > 0 -template -template<_GLIBCXX_TEMPLATE_PARAMS> - typename result_of< - typename reference_wrapper<_Tp>::_M_func_type(_GLIBCXX_TEMPLATE_ARGS)>::type - reference_wrapper<_Tp>::operator()(_GLIBCXX_REF_PARAMS) const - { - return __invoke(get(), _GLIBCXX_ARGS); - } -#endif - -#if _GLIBCXX_NUM_ARGS > 0 -template - class _Mem_fn<_Res (_Class::*)(_GLIBCXX_TEMPLATE_ARGS_SHIFTED)> -#if _GLIBCXX_NUM_ARGS == 1 - : public unary_function<_Class*, _Res> -#elif _GLIBCXX_NUM_ARGS == 2 - : public binary_function<_Class*, _T1, _Res> -#endif - { - typedef _Res (_Class::*_Functor)(_GLIBCXX_TEMPLATE_ARGS_SHIFTED); - - template - _Res - _M_call(_Tp& __object, const volatile _Class * _GLIBCXX_COMMA_SHIFTED - _GLIBCXX_PARAMS_SHIFTED) const - { return (__object.*__pmf)(_GLIBCXX_ARGS_SHIFTED); } - - template - _Res - _M_call(_Tp& __ptr, const volatile void * _GLIBCXX_COMMA_SHIFTED - _GLIBCXX_PARAMS_SHIFTED) const - { return ((*__ptr).*__pmf)(_GLIBCXX_ARGS_SHIFTED); } - - public: - typedef _Res result_type; - - explicit _Mem_fn(_Functor __pf) : __pmf(__pf) { } - - // Handle objects - _Res - operator()(_Class& __object _GLIBCXX_COMMA_SHIFTED - _GLIBCXX_PARAMS_SHIFTED) const - { return (__object.*__pmf)(_GLIBCXX_ARGS_SHIFTED); } - - // Handle pointers - _Res - operator()(_Class* __object _GLIBCXX_COMMA_SHIFTED - _GLIBCXX_PARAMS_SHIFTED) const - { return (__object->*__pmf)(_GLIBCXX_ARGS_SHIFTED); } - - // Handle smart pointers, references and pointers to derived - template - _Res - operator()(_Tp& __object _GLIBCXX_COMMA_SHIFTED - _GLIBCXX_PARAMS_SHIFTED) const - { - return _M_call(__object, &__object _GLIBCXX_COMMA_SHIFTED - _GLIBCXX_ARGS_SHIFTED); - } - - private: - _Functor __pmf; - }; - -template - class _Mem_fn<_Res (_Class::*)(_GLIBCXX_TEMPLATE_ARGS_SHIFTED) const> -#if _GLIBCXX_NUM_ARGS == 1 - : public unary_function -#elif _GLIBCXX_NUM_ARGS == 2 - : public binary_function -#endif - { - typedef _Res (_Class::*_Functor)(_GLIBCXX_TEMPLATE_ARGS_SHIFTED) const; - - template - _Res - _M_call(_Tp& __object, const volatile _Class * _GLIBCXX_COMMA_SHIFTED - _GLIBCXX_PARAMS_SHIFTED) const - { return (__object.*__pmf)(_GLIBCXX_ARGS_SHIFTED); } - - template - _Res - _M_call(_Tp& __ptr, const volatile void * _GLIBCXX_COMMA_SHIFTED - _GLIBCXX_PARAMS_SHIFTED) const - { return ((*__ptr).*__pmf)(_GLIBCXX_ARGS_SHIFTED); } - - public: - typedef _Res result_type; - - explicit _Mem_fn(_Functor __pf) : __pmf(__pf) { } - - // Handle objects - _Res - operator()(const _Class& __object _GLIBCXX_COMMA_SHIFTED - _GLIBCXX_PARAMS_SHIFTED) const - { return (__object.*__pmf)(_GLIBCXX_ARGS_SHIFTED); } - - // Handle pointers - _Res - operator()(const _Class* __object _GLIBCXX_COMMA_SHIFTED - _GLIBCXX_PARAMS_SHIFTED) const - { return (__object->*__pmf)(_GLIBCXX_ARGS_SHIFTED); } - - // Handle smart pointers, references and pointers to derived - template - _Res - operator()(_Tp& __object _GLIBCXX_COMMA_SHIFTED - _GLIBCXX_PARAMS_SHIFTED) const - { - return _M_call(__object, &__object _GLIBCXX_COMMA_SHIFTED - _GLIBCXX_ARGS_SHIFTED); - } - - private: - _Functor __pmf; - }; - -template - class _Mem_fn<_Res (_Class::*)(_GLIBCXX_TEMPLATE_ARGS_SHIFTED) volatile> -#if _GLIBCXX_NUM_ARGS == 1 - : public unary_function -#elif _GLIBCXX_NUM_ARGS == 2 - : public binary_function -#endif - { - typedef _Res (_Class::*_Functor)(_GLIBCXX_TEMPLATE_ARGS_SHIFTED) volatile; - - template - _Res - _M_call(_Tp& __object, const volatile _Class * _GLIBCXX_COMMA_SHIFTED - _GLIBCXX_PARAMS_SHIFTED) const - { return (__object.*__pmf)(_GLIBCXX_ARGS_SHIFTED); } - - template - _Res - _M_call(_Tp& __ptr, const volatile void * _GLIBCXX_COMMA_SHIFTED - _GLIBCXX_PARAMS_SHIFTED) const - { return ((*__ptr).*__pmf)(_GLIBCXX_ARGS_SHIFTED); } - - public: - typedef _Res result_type; - - explicit _Mem_fn(_Functor __pf) : __pmf(__pf) { } - - // Handle objects - _Res - operator()(volatile _Class& __object _GLIBCXX_COMMA_SHIFTED - _GLIBCXX_PARAMS_SHIFTED) const - { return (__object.*__pmf)(_GLIBCXX_ARGS_SHIFTED); } - - // Handle pointers - _Res - operator()(volatile _Class* __object _GLIBCXX_COMMA_SHIFTED - _GLIBCXX_PARAMS_SHIFTED) const - { return (__object->*__pmf)(_GLIBCXX_ARGS_SHIFTED); } - - // Handle smart pointers, references and pointers to derived - template - _Res - operator()(_Tp& __object _GLIBCXX_COMMA_SHIFTED - _GLIBCXX_PARAMS_SHIFTED) const - { - return _M_call(__object, &__object _GLIBCXX_COMMA_SHIFTED - _GLIBCXX_ARGS_SHIFTED); - } - private: - _Functor __pmf; - }; - -template - class _Mem_fn<_Res(_Class::*)(_GLIBCXX_TEMPLATE_ARGS_SHIFTED) const volatile> -#if _GLIBCXX_NUM_ARGS == 1 - : public unary_function -#elif _GLIBCXX_NUM_ARGS == 2 - : public binary_function -#endif - { - typedef _Res (_Class::*_Functor)(_GLIBCXX_TEMPLATE_ARGS_SHIFTED) - const volatile; - - template - _Res - _M_call(_Tp& __object, const volatile _Class * _GLIBCXX_COMMA_SHIFTED - _GLIBCXX_PARAMS_SHIFTED) const - { return (__object.*__pmf)(_GLIBCXX_ARGS_SHIFTED); } - - template - _Res - _M_call(_Tp& __ptr, const volatile void * _GLIBCXX_COMMA_SHIFTED - _GLIBCXX_PARAMS_SHIFTED) const - { return ((*__ptr).*__pmf)(_GLIBCXX_ARGS_SHIFTED); } - - public: - typedef _Res result_type; - - explicit _Mem_fn(_Functor __pf) : __pmf(__pf) { } - - // Handle objects - _Res - operator()(const volatile _Class& __object _GLIBCXX_COMMA_SHIFTED - _GLIBCXX_PARAMS_SHIFTED) const - { return (__object.*__pmf)(_GLIBCXX_ARGS_SHIFTED); } - - // Handle pointers - _Res - operator()(const volatile _Class* __object _GLIBCXX_COMMA_SHIFTED - _GLIBCXX_PARAMS_SHIFTED) const - { return (__object->*__pmf)(_GLIBCXX_ARGS_SHIFTED); } - - // Handle smart pointers, references and pointers to derived - template - _Res - operator()(_Tp& __object _GLIBCXX_COMMA_SHIFTED - _GLIBCXX_PARAMS_SHIFTED) const - { - return _M_call(__object, &__object _GLIBCXX_COMMA_SHIFTED - _GLIBCXX_ARGS_SHIFTED); - } - - private: - _Functor __pmf; - }; -#endif - -#if _GLIBCXX_NUM_ARGS > 0 -namespace placeholders -{ -namespace -{ - _Placeholder<_GLIBCXX_NUM_ARGS> _GLIBCXX_JOIN(_,_GLIBCXX_NUM_ARGS); -} // anonymous namespace -} -#endif - -template -class _Bind<_Functor(_GLIBCXX_TEMPLATE_ARGS)> - : public _Weak_result_type<_Functor> -{ - typedef _Bind __self_type; - - _Functor _M_f; - _GLIBCXX_BIND_MEMBERS - - public: -#if _GLIBCXX_NUM_ARGS == 0 - explicit -#endif - _Bind(_Functor __f _GLIBCXX_COMMA _GLIBCXX_PARAMS) - : _M_f(__f) _GLIBCXX_COMMA _GLIBCXX_BIND_MEMBERS_INIT { } - -#define _GLIBCXX_BIND_REPEAT_HEADER -#include -#undef _GLIBCXX_BIND_REPEAT_HEADER -}; - -template -class _Bind_result<_Result, _Functor(_GLIBCXX_TEMPLATE_ARGS)> -{ - _Functor _M_f; - _GLIBCXX_BIND_MEMBERS - - public: - typedef _Result result_type; - -#if _GLIBCXX_NUM_ARGS == 0 - explicit -#endif - _Bind_result(_Functor __f _GLIBCXX_COMMA _GLIBCXX_PARAMS) - : _M_f(__f) _GLIBCXX_COMMA _GLIBCXX_BIND_MEMBERS_INIT { } - -#define _GLIBCXX_BIND_REPEAT_HEADER -#define _GLIBCXX_BIND_HAS_RESULT_TYPE -#include -#undef _GLIBCXX_BIND_HAS_RESULT_TYPE -#undef _GLIBCXX_BIND_REPEAT_HEADER -}; - -// Handle arbitrary function objects -template -inline -_Bind::type - (_GLIBCXX_TEMPLATE_ARGS)> -bind(_Functor __f _GLIBCXX_COMMA _GLIBCXX_PARAMS) -{ - typedef _Maybe_wrap_member_pointer<_Functor> __maybe_type; - typedef typename __maybe_type::type __functor_type; - typedef _Bind<__functor_type(_GLIBCXX_TEMPLATE_ARGS)> __result_type; - return __result_type(__maybe_type::__do_wrap(__f) - _GLIBCXX_COMMA _GLIBCXX_ARGS); -} - -template -inline -_Bind_result<_Result, - typename _Maybe_wrap_member_pointer<_Functor>::type - (_GLIBCXX_TEMPLATE_ARGS)> -bind(_Functor __f _GLIBCXX_COMMA _GLIBCXX_PARAMS) -{ - typedef _Maybe_wrap_member_pointer<_Functor> __maybe_type; - typedef typename __maybe_type::type __functor_type; - typedef _Bind_result<_Result, __functor_type(_GLIBCXX_TEMPLATE_ARGS)> - __result_type; - return __result_type(__maybe_type::__do_wrap(__f) - _GLIBCXX_COMMA _GLIBCXX_ARGS); -} - -template -class _Function_handler<_Res(_GLIBCXX_TEMPLATE_ARGS), _Functor> - : public _Function_base::_Base_manager<_Functor> -{ - typedef _Function_base::_Base_manager<_Functor> _Base; - - public: - static _Res - _M_invoke(const _Any_data& __functor _GLIBCXX_COMMA _GLIBCXX_PARAMS) - { - return (*_Base::_M_get_pointer(__functor))(_GLIBCXX_ARGS); - } -}; - -template -class _Function_handler - : public _Function_base::_Base_manager<_Functor> -{ - typedef _Function_base::_Base_manager<_Functor> _Base; - - public: - static void - _M_invoke(const _Any_data& __functor _GLIBCXX_COMMA _GLIBCXX_PARAMS) - { - (*_Base::_M_get_pointer(__functor))(_GLIBCXX_ARGS); - } -}; - -template -class _Function_handler<_Res(_GLIBCXX_TEMPLATE_ARGS), - reference_wrapper<_Functor> > - : public _Function_base::_Ref_manager<_Functor> -{ - typedef _Function_base::_Ref_manager<_Functor> _Base; - - public: - static _Res - _M_invoke(const _Any_data& __functor _GLIBCXX_COMMA _GLIBCXX_PARAMS) - { - return __callable_functor(**_Base::_M_get_pointer(__functor)) - (_GLIBCXX_ARGS); - } -}; - -template -class _Function_handler > - : public _Function_base::_Ref_manager<_Functor> -{ - typedef _Function_base::_Ref_manager<_Functor> _Base; - - public: - static void - _M_invoke(const _Any_data& __functor _GLIBCXX_COMMA _GLIBCXX_PARAMS) - { - __callable_functor(**_Base::_M_get_pointer(__functor))(_GLIBCXX_ARGS); - } -}; - -template -class _Function_handler<_Res(_GLIBCXX_TEMPLATE_ARGS), _Member _Class::*> - : public _Function_handler -{ - typedef _Function_handler - _Base; - - public: - static _Res - _M_invoke(const _Any_data& __functor _GLIBCXX_COMMA _GLIBCXX_PARAMS) - { - return std::_GLIBCXX_TR1::mem_fn(_Base::_M_get_pointer(__functor)->__value) - (_GLIBCXX_ARGS); - } -}; - -template -class _Function_handler - : public _Function_base::_Base_manager< - _Simple_type_wrapper< _Member _Class::* > > -{ - typedef _Member _Class::* _Functor; - typedef _Simple_type_wrapper< _Functor > _Wrapper; - typedef _Function_base::_Base_manager<_Wrapper> _Base; - - public: - static bool - _M_manager(_Any_data& __dest, const _Any_data& __source, - _Manager_operation __op) - { - switch (__op) { - case __get_type_info: - __dest._M_access() = &typeid(_Functor); - break; - - case __get_functor_ptr: - __dest._M_access<_Functor*>() = - &_Base::_M_get_pointer(__source)->__value; - break; - - default: - _Base::_M_manager(__dest, __source, __op); - } - return false; - } - - static void - _M_invoke(const _Any_data& __functor _GLIBCXX_COMMA _GLIBCXX_PARAMS) - { - std::_GLIBCXX_TR1::mem_fn(_Base::_M_get_pointer(__functor)->__value) - (_GLIBCXX_ARGS); - } -}; - -template -class function<_Res(_GLIBCXX_TEMPLATE_ARGS)> -#if _GLIBCXX_NUM_ARGS == 1 - : public unary_function<_T1, _Res>, private _Function_base -#elif _GLIBCXX_NUM_ARGS == 2 - : public binary_function<_T1, _T2, _Res>, private _Function_base -#else - : private _Function_base -#endif -{ - /** - * @if maint - * This class is used to implement the safe_bool idiom. - * @endif - */ - struct _Hidden_type - { - _Hidden_type* _M_bool; - }; - - /** - * @if maint - * This typedef is used to implement the safe_bool idiom. - * @endif - */ - typedef _Hidden_type* _Hidden_type::* _Safe_bool; - - typedef _Res _Signature_type(_GLIBCXX_TEMPLATE_ARGS); - - struct _Useless {}; - - public: - typedef _Res result_type; - - // [3.7.2.1] construct/copy/destroy - - /** - * @brief Default construct creates an empty function call wrapper. - * @post @c !(bool)*this - */ - function() : _Function_base() { } - - /** - * @brief Default construct creates an empty function call wrapper. - * @post @c !(bool)*this - */ - function(_M_clear_type*) : _Function_base() { } - - /** - * @brief %Function copy constructor. - * @param x A %function object with identical call signature. - * @pre @c (bool)*this == (bool)x - * - * The newly-created %function contains a copy of the target of @a - * x (if it has one). - */ - function(const function& __x); - - /** - * @brief Builds a %function that targets a copy of the incoming - * function object. - * @param f A %function object that is callable with parameters of - * type @c T1, @c T2, ..., @c TN and returns a value convertible - * to @c Res. - * - * The newly-created %function object will target a copy of @a - * f. If @a f is @c reference_wrapper, then this function - * object will contain a reference to the function object @c - * f.get(). If @a f is a NULL function pointer or NULL - * pointer-to-member, the newly-created object will be empty. - * - * If @a f is a non-NULL function pointer or an object of type @c - * reference_wrapper, this function will not throw. - */ - template - function(_Functor __f, - typename __gnu_cxx::__enable_if::value, _Useless>::__type = _Useless()); - - /** - * @brief %Function assignment operator. - * @param x A %function with identical call signature. - * @post @c (bool)*this == (bool)x - * @returns @c *this - * - * The target of @a x is copied to @c *this. If @a x has no - * target, then @c *this will be empty. - * - * If @a x targets a function pointer or a reference to a function - * object, then this operation will not throw an exception. - */ - function& operator=(const function& __x) - { - function(__x).swap(*this); - return *this; - } - - /** - * @brief %Function assignment to zero. - * @post @c !(bool)*this - * @returns @c *this - * - * The target of @a *this is deallocated, leaving it empty. - */ - function& operator=(_M_clear_type*) - { - if (_M_manager) { - _M_manager(_M_functor, _M_functor, __destroy_functor); - _M_manager = 0; - _M_invoker = 0; - } - return *this; - } - - /** - * @brief %Function assignment to a new target. - * @param f A %function object that is callable with parameters of - * type @c T1, @c T2, ..., @c TN and returns a value convertible - * to @c Res. - * @return @c *this - * - * This %function object wrapper will target a copy of @a - * f. If @a f is @c reference_wrapper, then this function - * object will contain a reference to the function object @c - * f.get(). If @a f is a NULL function pointer or NULL - * pointer-to-member, @c this object will be empty. - * - * If @a f is a non-NULL function pointer or an object of type @c - * reference_wrapper, this function will not throw. - */ - template - typename __gnu_cxx::__enable_if::value, function&>::__type - operator=(_Functor __f) - { - function(__f).swap(*this); - return *this; - } - - // [3.7.2.2] function modifiers - - /** - * @brief Swap the targets of two %function objects. - * @param f A %function with identical call signature. - * - * Swap the targets of @c this function object and @a f. This - * function will not throw an exception. - */ - void swap(function& __x) - { - _Any_data __old_functor = _M_functor; - _M_functor = __x._M_functor; - __x._M_functor = __old_functor; - _Manager_type __old_manager = _M_manager; - _M_manager = __x._M_manager; - __x._M_manager = __old_manager; - _Invoker_type __old_invoker = _M_invoker; - _M_invoker = __x._M_invoker; - __x._M_invoker = __old_invoker; - } - - // [3.7.2.3] function capacity - - /** - * @brief Determine if the %function wrapper has a target. - * - * @return @c true when this %function object contains a target, - * or @c false when it is empty. - * - * This function will not throw an exception. - */ - operator _Safe_bool() const - { - if (_M_empty()) - { - return 0; - } - else - { - return &_Hidden_type::_M_bool; - } - } - - // [3.7.2.4] function invocation - - /** - * @brief Invokes the function targeted by @c *this. - * @returns the result of the target. - * @throws bad_function_call when @c !(bool)*this - * - * The function call operator invokes the target function object - * stored by @c this. - */ - _Res operator()(_GLIBCXX_PARAMS) const; - - // [3.7.2.5] function target access - /** - * @brief Determine the type of the target of this function object - * wrapper. - * - * @returns the type identifier of the target function object, or - * @c typeid(void) if @c !(bool)*this. - * - * This function will not throw an exception. - */ - const type_info& target_type() const; - - /** - * @brief Access the stored target function object. - * - * @return Returns a pointer to the stored target function object, - * if @c typeid(Functor).equals(target_type()); otherwise, a NULL - * pointer. - * - * This function will not throw an exception. - */ - template _Functor* target(); - - /** - * @overload - */ - template const _Functor* target() const; - - private: - // [3.7.2.6] undefined operators - template - void operator==(const function<_Function>&) const; - template - void operator!=(const function<_Function>&) const; - - typedef _Res (*_Invoker_type)(const _Any_data& _GLIBCXX_COMMA - _GLIBCXX_PARAMS); - _Invoker_type _M_invoker; -}; - -template - function<_Res(_GLIBCXX_TEMPLATE_ARGS)>::function(const function& __x) - : _Function_base() - { - if (__x) { - _M_invoker = __x._M_invoker; - _M_manager = __x._M_manager; - __x._M_manager(_M_functor, __x._M_functor, __clone_functor); - } - } - -template -template - function<_Res(_GLIBCXX_TEMPLATE_ARGS)> - ::function(_Functor __f, - typename __gnu_cxx::__enable_if::value, _Useless>::__type) - : _Function_base() -{ - typedef _Function_handler<_Signature_type, _Functor> _My_handler; - if (_My_handler::_M_not_empty_function(__f)) { - _M_invoker = &_My_handler::_M_invoke; - _M_manager = &_My_handler::_M_manager; - _My_handler::_M_init_functor(_M_functor, __f); - } -} - -template - _Res - function<_Res(_GLIBCXX_TEMPLATE_ARGS)>::operator()(_GLIBCXX_PARAMS) const - { - if (_M_empty()) - { -#if __EXCEPTIONS - throw bad_function_call(); -#else - std::abort(); -#endif - } - return _M_invoker(_M_functor _GLIBCXX_COMMA _GLIBCXX_ARGS); - } - -template - const type_info& - function<_Res(_GLIBCXX_TEMPLATE_ARGS)>::target_type() const - { - if (_M_manager) - { - _Any_data __typeinfo_result; - _M_manager(__typeinfo_result, _M_functor, __get_type_info); - return *__typeinfo_result._M_access(); - } - else - { - return typeid(void); - } - } - -template -template - _Functor* - function<_Res(_GLIBCXX_TEMPLATE_ARGS)>::target() - { - if (typeid(_Functor) == target_type() && _M_manager) - { - _Any_data __ptr; - if (_M_manager(__ptr, _M_functor, __get_functor_ptr) - && !is_const<_Functor>::value) - return 0; - else - return __ptr._M_access<_Functor*>(); - } - else - { - return 0; - } - } - -template -template - const _Functor* - function<_Res(_GLIBCXX_TEMPLATE_ARGS)>::target() const - { - if (typeid(_Functor) == target_type() && _M_manager) - { - _Any_data __ptr; - _M_manager(__ptr, _M_functor, __get_functor_ptr); - return __ptr._M_access(); - } - else - { - return 0; - } - } - -_GLIBCXX_END_NAMESPACE -} diff --git a/libstdc++-v3/include/tr1/mu_iterate.h b/libstdc++-v3/include/tr1/mu_iterate.h deleted file mode 100644 index abdc724..0000000 --- a/libstdc++-v3/include/tr1/mu_iterate.h +++ /dev/null @@ -1,52 +0,0 @@ -// TR1 functional -*- C++ -*- - -// Copyright (C) 2005 Free Software Foundation, Inc. -// Written by Douglas Gregor -// -// 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/mu_iterate.h - * This is an internal header file, included by other library headers. - * You should not attempt to use it directly. - */ - -// Determine the result type when we pass the arguments along. This -// involves passing along the cv-qualifiers placed on _Mu and -// unwrapping the argument bundle. -// @namespace std::tr1 -// @class std::tr1::_Mu::result -template -class result<_CVMu(_CVArg, tuple<_GLIBCXX_TEMPLATE_ARGS>)> - : public result_of<_CVArg(_GLIBCXX_TEMPLATE_ARGS)> { }; - -template -typename result_of<_CVArg(_GLIBCXX_TEMPLATE_ARGS)>::type -operator()(_CVArg& __arg, const tuple<_GLIBCXX_TEMPLATE_ARGS>& __tuple) - const volatile -{ - return __arg(_GLIBCXX_MU_GET_TUPLE_ARGS); -} diff --git a/libstdc++-v3/include/tr1/ref_wrap_iterate.h b/libstdc++-v3/include/tr1/ref_wrap_iterate.h deleted file mode 100644 index 7c63d2c..0000000 --- a/libstdc++-v3/include/tr1/ref_wrap_iterate.h +++ /dev/null @@ -1,44 +0,0 @@ -// TR1 reference_wrapper -*- C++ -*- - -// Copyright (C) 2005 Free Software Foundation, Inc. -// Written by Douglas Gregor -// -// 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/ref_wrap_iterate.h - * This is an internal header file, included by other library headers. - * You should not attempt to use it directly. - */ - -#if _GLIBCXX_NUM_ARGS > 0 -template<_GLIBCXX_TEMPLATE_PARAMS> - typename result_of<_M_func_type(_GLIBCXX_TEMPLATE_ARGS)>::type - operator()(_GLIBCXX_REF_PARAMS) const; -#else -typename result_of<_M_func_type()>::type -operator()() const -{ return get()(); } -#endif diff --git a/libstdc++-v3/include/tr1/repeat.h b/libstdc++-v3/include/tr1/repeat.h deleted file mode 100644 index 9410d71..0000000 --- a/libstdc++-v3/include/tr1/repeat.h +++ /dev/null @@ -1,677 +0,0 @@ -// TR1 code repetition -*- C++ -*- - -// Copyright (C) 2005, 2007 Free Software Foundation, Inc. -// Written by Douglas Gregor -// -// 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/repeat.h - * This is an internal header file, included by other library headers. - * You should not attempt to use it directly. - */ - -#ifndef _GLIBCXX_REPEAT_HEADER -# error Internal error: _GLIBCXX_REPEAT_HEADER must be set -#endif /* _GLIBCXX_REPEAT_HEADER */ - -#ifndef _GLIBCXX_TUPLE_ALL_TEMPLATE_PARAMS -# define _GLIBCXX_TUPLE_ALL_TEMPLATE_PARAMS typename _T1, typename _T2, typename _T3, typename _T4, typename _T5, typename _T6, typename _T7, typename _T8, typename _T9, typename _T10 -# define _GLIBCXX_TUPLE_ALL_TEMPLATE_PARAMS_UNNAMED typename, typename, typename, typename, typename, typename, typename, typename, typename, typename -# define _GLIBCXX_TUPLE_ALL_TEMPLATE_ARGS _T1, _T2, _T3, _T4, _T5, _T6, _T7, _T8, _T9, _T10 -#endif - -#define _GLIBCXX_NUM_ARGS 0 -#define _GLIBCXX_COMMA -#define _GLIBCXX_TEMPLATE_PARAMS -#define _GLIBCXX_TEMPLATE_ARGS -#define _GLIBCXX_PARAMS -#define _GLIBCXX_REF_PARAMS -#define _GLIBCXX_ARGS -#define _GLIBCXX_COMMA_SHIFTED -#define _GLIBCXX_TEMPLATE_PARAMS_SHIFTED -#define _GLIBCXX_TEMPLATE_ARGS_SHIFTED -#define _GLIBCXX_PARAMS_SHIFTED -#define _GLIBCXX_ARGS_SHIFTED -#define _GLIBCXX_BIND_MEMBERS_INIT -#define _GLIBCXX_BIND_MEMBERS -#define _GLIBCXX_MU_GET_TUPLE_ARGS -#define _GLIBCXX_BIND_V_TEMPLATE_ARGS(_CV) -#define _GLIBCXX_BIND_V_ARGS -#define _GLIBCXX_TUPLE_ADD_CREF -#define _GLIBCXX_TUPLE_COPY_INIT -#define _GLIBCXX_TUPLE_ASSIGN -#define _GLIBCXX_TEMPLATE_PARAMS_NULL_CLASS -#define _GLIBCXX_TEMPLATE_ARGS_STRIPPED -#define _GLIBCXX_TEMPLATE_PARAMS_U -#define _GLIBCXX_TEMPLATE_ARGS_U -#define _GLIBCXX_REF_WRAP_PARAMS -#define _GLIBCXX_REF_TEMPLATE_ARGS -#define _GLIBCXX_NUM_ARGS_PLUS_1 1 -#define _GLIBCXX_T_NUM_ARGS_PLUS_1 _T1 -#include _GLIBCXX_REPEAT_HEADER -#undef _GLIBCXX_T_NUM_ARGS_PLUS_1 -#undef _GLIBCXX_NUM_ARGS_PLUS_1 -#undef _GLIBCXX_REF_TEMPLATE_ARGS -#undef _GLIBCXX_REF_WRAP_PARAMS -#undef _GLIBCXX_TEMPLATE_ARGS_U -#undef _GLIBCXX_TEMPLATE_PARAMS_U -#undef _GLIBCXX_TEMPLATE_ARGS_STRIPPED -#undef _GLIBCXX_TEMPLATE_PARAMS_NULL_CLASS -#undef _GLIBCXX_TUPLE_ASSIGN -#undef _GLIBCXX_TUPLE_COPY_INIT -#undef _GLIBCXX_TUPLE_ADD_CREF -#undef _GLIBCXX_BIND_V_ARGS -#undef _GLIBCXX_BIND_V_TEMPLATE_ARGS -#undef _GLIBCXX_MU_GET_TUPLE_ARGS -#undef _GLIBCXX_BIND_MEMBERS_INIT -#undef _GLIBCXX_BIND_MEMBERS -#undef _GLIBCXX_ARGS_SHIFTED -#undef _GLIBCXX_PARAMS_SHIFTED -#undef _GLIBCXX_TEMPLATE_ARGS_SHIFTED -#undef _GLIBCXX_TEMPLATE_PARAMS_SHIFTED -#undef _GLIBCXX_COMMA_SHIFTED -#undef _GLIBCXX_ARGS -#undef _GLIBCXX_REF_PARAMS -#undef _GLIBCXX_PARAMS -#undef _GLIBCXX_TEMPLATE_ARGS -#undef _GLIBCXX_TEMPLATE_PARAMS -#undef _GLIBCXX_COMMA -#undef _GLIBCXX_NUM_ARGS - -#define _GLIBCXX_NUM_ARGS 1 -#define _GLIBCXX_COMMA , -#define _GLIBCXX_TEMPLATE_PARAMS typename _T1 -#define _GLIBCXX_TEMPLATE_ARGS _T1 -#define _GLIBCXX_PARAMS _T1 __a1 -#define _GLIBCXX_REF_PARAMS _T1& __a1 -#define _GLIBCXX_ARGS __a1 -#define _GLIBCXX_COMMA_SHIFTED -#define _GLIBCXX_TEMPLATE_PARAMS_SHIFTED -#define _GLIBCXX_TEMPLATE_ARGS_SHIFTED -#define _GLIBCXX_PARAMS_SHIFTED -#define _GLIBCXX_ARGS_SHIFTED -#define _GLIBCXX_BIND_MEMBERS _T1 _M_arg1; -#define _GLIBCXX_BIND_MEMBERS_INIT _M_arg1(__a1) -#define _GLIBCXX_MU_GET_TUPLE_ARGS ::std::_GLIBCXX_TR1::get<0>(__tuple) -#define _GLIBCXX_BIND_V_TEMPLATE_ARGS(_CV) typename result_of<_Mu<_T1> _CV(_T1, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type -#define _GLIBCXX_BIND_V_ARGS _Mu<_T1>()(_M_arg1, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)) -#define _GLIBCXX_TUPLE_ADD_CREF typename __add_c_ref<_T1>::type __a1 -#define _GLIBCXX_TUPLE_COPY_INIT _M_arg1(__in._M_arg1) -#define _GLIBCXX_TUPLE_ASSIGN _M_arg1 = __in._M_arg1; -#define _GLIBCXX_TEMPLATE_PARAMS_NULL_CLASS typename _T1 = _NullClass -#define _GLIBCXX_TEMPLATE_ARGS_STRIPPED typename __strip_reference_wrapper<_T1>::__type -#define _GLIBCXX_TEMPLATE_PARAMS_U typename _U1 -#define _GLIBCXX_TEMPLATE_ARGS_U _U1 -#define _GLIBCXX_REF_WRAP_PARAMS ref(__a1) -#define _GLIBCXX_REF_TEMPLATE_ARGS _T1& -#define _GLIBCXX_NUM_ARGS_PLUS_1 2 -#define _GLIBCXX_T_NUM_ARGS_PLUS_1 _T2 -#include _GLIBCXX_REPEAT_HEADER -#undef _GLIBCXX_T_NUM_ARGS_PLUS_1 -#undef _GLIBCXX_NUM_ARGS_PLUS_1 -#undef _GLIBCXX_REF_TEMPLATE_ARGS -#undef _GLIBCXX_REF_WRAP_PARAMS -#undef _GLIBCXX_TEMPLATE_ARGS_U -#undef _GLIBCXX_TEMPLATE_PARAMS_U -#undef _GLIBCXX_TEMPLATE_ARGS_STRIPPED -#undef _GLIBCXX_TEMPLATE_PARAMS_NULL_CLASS -#undef _GLIBCXX_TUPLE_ASSIGN -#undef _GLIBCXX_TUPLE_COPY_INIT -#undef _GLIBCXX_TUPLE_ADD_CREF -#undef _GLIBCXX_BIND_V_ARGS -#undef _GLIBCXX_BIND_V_TEMPLATE_ARGS -#undef _GLIBCXX_MU_GET_TUPLE_ARGS -#undef _GLIBCXX_BIND_MEMBERS_INIT -#undef _GLIBCXX_BIND_MEMBERS -#undef _GLIBCXX_ARGS_SHIFTED -#undef _GLIBCXX_PARAMS_SHIFTED -#undef _GLIBCXX_TEMPLATE_ARGS_SHIFTED -#undef _GLIBCXX_TEMPLATE_PARAMS_SHIFTED -#undef _GLIBCXX_COMMA_SHIFTED -#undef _GLIBCXX_ARGS -#undef _GLIBCXX_REF_PARAMS -#undef _GLIBCXX_PARAMS -#undef _GLIBCXX_TEMPLATE_ARGS -#undef _GLIBCXX_TEMPLATE_PARAMS -#undef _GLIBCXX_COMMA -#undef _GLIBCXX_NUM_ARGS - -#define _GLIBCXX_NUM_ARGS 2 -#define _GLIBCXX_COMMA , -#define _GLIBCXX_TEMPLATE_PARAMS typename _T1, typename _T2 -#define _GLIBCXX_TEMPLATE_ARGS _T1, _T2 -#define _GLIBCXX_PARAMS _T1 __a1, _T2 __a2 -#define _GLIBCXX_REF_PARAMS _T1& __a1, _T2& __a2 -#define _GLIBCXX_ARGS __a1, __a2 -#define _GLIBCXX_COMMA_SHIFTED , -#define _GLIBCXX_TEMPLATE_PARAMS_SHIFTED typename _T1 -#define _GLIBCXX_TEMPLATE_ARGS_SHIFTED _T1 -#define _GLIBCXX_PARAMS_SHIFTED _T1 __a1 -#define _GLIBCXX_ARGS_SHIFTED __a1 -#define _GLIBCXX_BIND_MEMBERS _T1 _M_arg1; _T2 _M_arg2; -#define _GLIBCXX_BIND_MEMBERS_INIT _M_arg1(__a1), _M_arg2(__a2) -#define _GLIBCXX_MU_GET_TUPLE_ARGS ::std::_GLIBCXX_TR1::get<0>(__tuple), ::std::_GLIBCXX_TR1::get<1>(__tuple) -#define _GLIBCXX_BIND_V_TEMPLATE_ARGS(_CV) typename result_of<_Mu<_T1> _CV(_T1, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T2> _CV(_T2, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type -#define _GLIBCXX_BIND_V_ARGS _Mu<_T1>()(_M_arg1, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T2>()(_M_arg2, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)) -#define _GLIBCXX_TUPLE_ADD_CREF typename __add_c_ref<_T1>::type __a1, typename __add_c_ref<_T2>::type __a2 -#define _GLIBCXX_TUPLE_COPY_INIT _M_arg1(__in._M_arg1), _M_arg2(__in._M_arg2) -#define _GLIBCXX_TUPLE_ASSIGN _M_arg1 = __in._M_arg1; _M_arg2 = __in._M_arg2; -#define _GLIBCXX_TEMPLATE_PARAMS_NULL_CLASS typename _T1 = _NullClass, typename _T2 = _NullClass -#define _GLIBCXX_TEMPLATE_ARGS_STRIPPED typename __strip_reference_wrapper<_T1>::__type, typename __strip_reference_wrapper<_T2>::__type -#define _GLIBCXX_TEMPLATE_PARAMS_U typename _U1, typename _U2 -#define _GLIBCXX_TEMPLATE_ARGS_U _U1, _U2 -#define _GLIBCXX_REF_WRAP_PARAMS ref(__a1), ref(__a2) -#define _GLIBCXX_REF_TEMPLATE_ARGS _T1&, _T2& -#define _GLIBCXX_NUM_ARGS_PLUS_1 3 -#define _GLIBCXX_T_NUM_ARGS_PLUS_1 _T3 -#include _GLIBCXX_REPEAT_HEADER -#undef _GLIBCXX_T_NUM_ARGS_PLUS_1 -#undef _GLIBCXX_NUM_ARGS_PLUS_1 -#undef _GLIBCXX_REF_TEMPLATE_ARGS -#undef _GLIBCXX_REF_WRAP_PARAMS -#undef _GLIBCXX_TEMPLATE_ARGS_U -#undef _GLIBCXX_TEMPLATE_PARAMS_U -#undef _GLIBCXX_TEMPLATE_ARGS_STRIPPED -#undef _GLIBCXX_TEMPLATE_PARAMS_NULL_CLASS -#undef _GLIBCXX_TUPLE_ASSIGN -#undef _GLIBCXX_TUPLE_COPY_INIT -#undef _GLIBCXX_TUPLE_ADD_CREF -#undef _GLIBCXX_BIND_V_ARGS -#undef _GLIBCXX_BIND_V_TEMPLATE_ARGS -#undef _GLIBCXX_MU_GET_TUPLE_ARGS -#undef _GLIBCXX_BIND_MEMBERS_INIT -#undef _GLIBCXX_BIND_MEMBERS -#undef _GLIBCXX_ARGS_SHIFTED -#undef _GLIBCXX_PARAMS_SHIFTED -#undef _GLIBCXX_TEMPLATE_ARGS_SHIFTED -#undef _GLIBCXX_TEMPLATE_PARAMS_SHIFTED -#undef _GLIBCXX_COMMA_SHIFTED -#undef _GLIBCXX_ARGS -#undef _GLIBCXX_REF_PARAMS -#undef _GLIBCXX_PARAMS -#undef _GLIBCXX_TEMPLATE_ARGS -#undef _GLIBCXX_TEMPLATE_PARAMS -#undef _GLIBCXX_COMMA -#undef _GLIBCXX_NUM_ARGS -#define _GLIBCXX_NUM_ARGS 3 -#define _GLIBCXX_COMMA , -#define _GLIBCXX_TEMPLATE_PARAMS typename _T1, typename _T2, typename _T3 -#define _GLIBCXX_TEMPLATE_ARGS _T1, _T2, _T3 -#define _GLIBCXX_PARAMS _T1 __a1, _T2 __a2, _T3 __a3 -#define _GLIBCXX_REF_PARAMS _T1& __a1, _T2& __a2, _T3& __a3 -#define _GLIBCXX_ARGS __a1, __a2, __a3 -#define _GLIBCXX_COMMA_SHIFTED , -#define _GLIBCXX_TEMPLATE_PARAMS_SHIFTED typename _T1, typename _T2 -#define _GLIBCXX_TEMPLATE_ARGS_SHIFTED _T1, _T2 -#define _GLIBCXX_PARAMS_SHIFTED _T1 __a1, _T2 __a2 -#define _GLIBCXX_ARGS_SHIFTED __a1, __a2 -#define _GLIBCXX_BIND_MEMBERS _T1 _M_arg1; _T2 _M_arg2; _T3 _M_arg3; -#define _GLIBCXX_BIND_MEMBERS_INIT _M_arg1(__a1), _M_arg2(__a2), _M_arg3(__a3) -#define _GLIBCXX_MU_GET_TUPLE_ARGS ::std::_GLIBCXX_TR1::get<0>(__tuple), ::std::_GLIBCXX_TR1::get<1>(__tuple), ::std::_GLIBCXX_TR1::get<2>(__tuple) -#define _GLIBCXX_BIND_V_TEMPLATE_ARGS(_CV) typename result_of<_Mu<_T1> _CV(_T1, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T2> _CV(_T2, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T3> _CV(_T3, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type -#define _GLIBCXX_BIND_V_ARGS _Mu<_T1>()(_M_arg1, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T2>()(_M_arg2, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T3>()(_M_arg3, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)) -#define _GLIBCXX_TUPLE_ADD_CREF typename __add_c_ref<_T1>::type __a1, typename __add_c_ref<_T2>::type __a2, typename __add_c_ref<_T3>::type __a3 -#define _GLIBCXX_TUPLE_COPY_INIT _M_arg1(__in._M_arg1), _M_arg2(__in._M_arg2), _M_arg3(__in._M_arg3) -#define _GLIBCXX_TUPLE_ASSIGN _M_arg1 = __in._M_arg1; _M_arg2 = __in._M_arg2; _M_arg3 = __in._M_arg3; -#define _GLIBCXX_TEMPLATE_PARAMS_NULL_CLASS typename _T1 = _NullClass, typename _T2 = _NullClass, typename _T3 = _NullClass -#define _GLIBCXX_TEMPLATE_ARGS_STRIPPED typename __strip_reference_wrapper<_T1>::__type, typename __strip_reference_wrapper<_T2>::__type, typename __strip_reference_wrapper<_T3>::__type -#define _GLIBCXX_TEMPLATE_PARAMS_U typename _U1, typename _U2, typename _U3 -#define _GLIBCXX_TEMPLATE_ARGS_U _U1, _U2, _U3 -#define _GLIBCXX_REF_WRAP_PARAMS ref(__a1), ref(__a2), ref(__a3) -#define _GLIBCXX_REF_TEMPLATE_ARGS _T1&, _T2&, _T3& -#define _GLIBCXX_NUM_ARGS_PLUS_1 4 -#define _GLIBCXX_T_NUM_ARGS_PLUS_1 _T4 -#include _GLIBCXX_REPEAT_HEADER -#undef _GLIBCXX_T_NUM_ARGS_PLUS_1 -#undef _GLIBCXX_NUM_ARGS_PLUS_1 -#undef _GLIBCXX_REF_TEMPLATE_ARGS -#undef _GLIBCXX_REF_WRAP_PARAMS -#undef _GLIBCXX_TEMPLATE_ARGS_U -#undef _GLIBCXX_TEMPLATE_PARAMS_U -#undef _GLIBCXX_TEMPLATE_ARGS_STRIPPED -#undef _GLIBCXX_TEMPLATE_PARAMS_NULL_CLASS -#undef _GLIBCXX_TUPLE_ASSIGN -#undef _GLIBCXX_TUPLE_COPY_INIT -#undef _GLIBCXX_TUPLE_ADD_CREF -#undef _GLIBCXX_BIND_V_ARGS -#undef _GLIBCXX_BIND_V_TEMPLATE_ARGS -#undef _GLIBCXX_MU_GET_TUPLE_ARGS -#undef _GLIBCXX_BIND_MEMBERS_INIT -#undef _GLIBCXX_BIND_MEMBERS -#undef _GLIBCXX_ARGS_SHIFTED -#undef _GLIBCXX_PARAMS_SHIFTED -#undef _GLIBCXX_TEMPLATE_ARGS_SHIFTED -#undef _GLIBCXX_TEMPLATE_PARAMS_SHIFTED -#undef _GLIBCXX_COMMA_SHIFTED -#undef _GLIBCXX_ARGS -#undef _GLIBCXX_REF_PARAMS -#undef _GLIBCXX_PARAMS -#undef _GLIBCXX_TEMPLATE_ARGS -#undef _GLIBCXX_TEMPLATE_PARAMS -#undef _GLIBCXX_COMMA -#undef _GLIBCXX_NUM_ARGS -#define _GLIBCXX_NUM_ARGS 4 -#define _GLIBCXX_COMMA , -#define _GLIBCXX_TEMPLATE_PARAMS typename _T1, typename _T2, typename _T3, typename _T4 -#define _GLIBCXX_TEMPLATE_ARGS _T1, _T2, _T3, _T4 -#define _GLIBCXX_PARAMS _T1 __a1, _T2 __a2, _T3 __a3, _T4 __a4 -#define _GLIBCXX_REF_PARAMS _T1& __a1, _T2& __a2, _T3& __a3, _T4& __a4 -#define _GLIBCXX_ARGS __a1, __a2, __a3, __a4 -#define _GLIBCXX_COMMA_SHIFTED , -#define _GLIBCXX_TEMPLATE_PARAMS_SHIFTED typename _T1, typename _T2, typename _T3 -#define _GLIBCXX_TEMPLATE_ARGS_SHIFTED _T1, _T2, _T3 -#define _GLIBCXX_PARAMS_SHIFTED _T1 __a1, _T2 __a2, _T3 __a3 -#define _GLIBCXX_ARGS_SHIFTED __a1, __a2, __a3 -#define _GLIBCXX_BIND_MEMBERS _T1 _M_arg1; _T2 _M_arg2; _T3 _M_arg3; _T4 _M_arg4; -#define _GLIBCXX_BIND_MEMBERS_INIT _M_arg1(__a1), _M_arg2(__a2), _M_arg3(__a3), _M_arg4(__a4) -#define _GLIBCXX_MU_GET_TUPLE_ARGS ::std::_GLIBCXX_TR1::get<0>(__tuple), ::std::_GLIBCXX_TR1::get<1>(__tuple), ::std::_GLIBCXX_TR1::get<2>(__tuple), ::std::_GLIBCXX_TR1::get<3>(__tuple) -#define _GLIBCXX_BIND_V_TEMPLATE_ARGS(_CV) typename result_of<_Mu<_T1> _CV(_T1, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T2> _CV(_T2, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T3> _CV(_T3, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T4> _CV(_T4, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type -#define _GLIBCXX_BIND_V_ARGS _Mu<_T1>()(_M_arg1, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T2>()(_M_arg2, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T3>()(_M_arg3, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T4>()(_M_arg4, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)) -#define _GLIBCXX_TUPLE_ADD_CREF typename __add_c_ref<_T1>::type __a1, typename __add_c_ref<_T2>::type __a2, typename __add_c_ref<_T3>::type __a3, typename __add_c_ref<_T4>::type __a4 -#define _GLIBCXX_TUPLE_COPY_INIT _M_arg1(__in._M_arg1), _M_arg2(__in._M_arg2), _M_arg3(__in._M_arg3), _M_arg4(__in._M_arg4) -#define _GLIBCXX_TUPLE_ASSIGN _M_arg1 = __in._M_arg1; _M_arg2 = __in._M_arg2; _M_arg3 = __in._M_arg3; _M_arg4 = __in._M_arg4; -#define _GLIBCXX_TEMPLATE_PARAMS_NULL_CLASS typename _T1 = _NullClass, typename _T2 = _NullClass, typename _T3 = _NullClass, typename _T4 = _NullClass -#define _GLIBCXX_TEMPLATE_ARGS_STRIPPED typename __strip_reference_wrapper<_T1>::__type, typename __strip_reference_wrapper<_T2>::__type, typename __strip_reference_wrapper<_T3>::__type, typename __strip_reference_wrapper<_T4>::__type -#define _GLIBCXX_TEMPLATE_PARAMS_U typename _U1, typename _U2, typename _U3, typename _U4 -#define _GLIBCXX_TEMPLATE_ARGS_U _U1, _U2, _U3, _U4 -#define _GLIBCXX_REF_WRAP_PARAMS ref(__a1), ref(__a2), ref(__a3), ref(__a4) -#define _GLIBCXX_REF_TEMPLATE_ARGS _T1&, _T2&, _T3&, _T4& -#define _GLIBCXX_NUM_ARGS_PLUS_1 5 -#define _GLIBCXX_T_NUM_ARGS_PLUS_1 _T5 -#include _GLIBCXX_REPEAT_HEADER -#undef _GLIBCXX_T_NUM_ARGS_PLUS_1 -#undef _GLIBCXX_NUM_ARGS_PLUS_1 -#undef _GLIBCXX_REF_TEMPLATE_ARGS -#undef _GLIBCXX_REF_WRAP_PARAMS -#undef _GLIBCXX_TEMPLATE_ARGS_U -#undef _GLIBCXX_TEMPLATE_PARAMS_U -#undef _GLIBCXX_TEMPLATE_ARGS_STRIPPED -#undef _GLIBCXX_TEMPLATE_PARAMS_NULL_CLASS -#undef _GLIBCXX_TUPLE_ASSIGN -#undef _GLIBCXX_TUPLE_COPY_INIT -#undef _GLIBCXX_TUPLE_ADD_CREF -#undef _GLIBCXX_BIND_V_ARGS -#undef _GLIBCXX_BIND_V_TEMPLATE_ARGS -#undef _GLIBCXX_MU_GET_TUPLE_ARGS -#undef _GLIBCXX_BIND_MEMBERS_INIT -#undef _GLIBCXX_BIND_MEMBERS -#undef _GLIBCXX_ARGS_SHIFTED -#undef _GLIBCXX_PARAMS_SHIFTED -#undef _GLIBCXX_TEMPLATE_ARGS_SHIFTED -#undef _GLIBCXX_TEMPLATE_PARAMS_SHIFTED -#undef _GLIBCXX_COMMA_SHIFTED -#undef _GLIBCXX_ARGS -#undef _GLIBCXX_REF_PARAMS -#undef _GLIBCXX_PARAMS -#undef _GLIBCXX_TEMPLATE_ARGS -#undef _GLIBCXX_TEMPLATE_PARAMS -#undef _GLIBCXX_COMMA -#undef _GLIBCXX_NUM_ARGS -#define _GLIBCXX_NUM_ARGS 5 -#define _GLIBCXX_COMMA , -#define _GLIBCXX_TEMPLATE_PARAMS typename _T1, typename _T2, typename _T3, typename _T4, typename _T5 -#define _GLIBCXX_TEMPLATE_ARGS _T1, _T2, _T3, _T4, _T5 -#define _GLIBCXX_PARAMS _T1 __a1, _T2 __a2, _T3 __a3, _T4 __a4, _T5 __a5 -#define _GLIBCXX_REF_PARAMS _T1& __a1, _T2& __a2, _T3& __a3, _T4& __a4, _T5& __a5 -#define _GLIBCXX_ARGS __a1, __a2, __a3, __a4, __a5 -#define _GLIBCXX_COMMA_SHIFTED , -#define _GLIBCXX_TEMPLATE_PARAMS_SHIFTED typename _T1, typename _T2, typename _T3, typename _T4 -#define _GLIBCXX_TEMPLATE_ARGS_SHIFTED _T1, _T2, _T3, _T4 -#define _GLIBCXX_PARAMS_SHIFTED _T1 __a1, _T2 __a2, _T3 __a3, _T4 __a4 -#define _GLIBCXX_ARGS_SHIFTED __a1, __a2, __a3, __a4 -#define _GLIBCXX_BIND_MEMBERS _T1 _M_arg1; _T2 _M_arg2; _T3 _M_arg3; _T4 _M_arg4; _T5 _M_arg5; -#define _GLIBCXX_BIND_MEMBERS_INIT _M_arg1(__a1), _M_arg2(__a2), _M_arg3(__a3), _M_arg4(__a4), _M_arg5(__a5) -#define _GLIBCXX_MU_GET_TUPLE_ARGS ::std::_GLIBCXX_TR1::get<0>(__tuple), ::std::_GLIBCXX_TR1::get<1>(__tuple), ::std::_GLIBCXX_TR1::get<2>(__tuple), ::std::_GLIBCXX_TR1::get<3>(__tuple), ::std::_GLIBCXX_TR1::get<4>(__tuple) -#define _GLIBCXX_BIND_V_TEMPLATE_ARGS(_CV) typename result_of<_Mu<_T1> _CV(_T1, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T2> _CV(_T2, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T3> _CV(_T3, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T4> _CV(_T4, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T5> _CV(_T5, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type -#define _GLIBCXX_BIND_V_ARGS _Mu<_T1>()(_M_arg1, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T2>()(_M_arg2, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T3>()(_M_arg3, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T4>()(_M_arg4, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T5>()(_M_arg5, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)) -#define _GLIBCXX_TUPLE_ADD_CREF typename __add_c_ref<_T1>::type __a1, typename __add_c_ref<_T2>::type __a2, typename __add_c_ref<_T3>::type __a3, typename __add_c_ref<_T4>::type __a4, typename __add_c_ref<_T5>::type __a5 -#define _GLIBCXX_TUPLE_COPY_INIT _M_arg1(__in._M_arg1), _M_arg2(__in._M_arg2), _M_arg3(__in._M_arg3), _M_arg4(__in._M_arg4), _M_arg5(__in._M_arg5) -#define _GLIBCXX_TUPLE_ASSIGN _M_arg1 = __in._M_arg1; _M_arg2 = __in._M_arg2; _M_arg3 = __in._M_arg3; _M_arg4 = __in._M_arg4; _M_arg5 = __in._M_arg5; -#define _GLIBCXX_TEMPLATE_PARAMS_NULL_CLASS typename _T1 = _NullClass, typename _T2 = _NullClass, typename _T3 = _NullClass, typename _T4 = _NullClass, typename _T5 = _NullClass -#define _GLIBCXX_TEMPLATE_ARGS_STRIPPED typename __strip_reference_wrapper<_T1>::__type, typename __strip_reference_wrapper<_T2>::__type, typename __strip_reference_wrapper<_T3>::__type, typename __strip_reference_wrapper<_T4>::__type, typename __strip_reference_wrapper<_T5>::__type -#define _GLIBCXX_TEMPLATE_PARAMS_U typename _U1, typename _U2, typename _U3, typename _U4, typename _U5 -#define _GLIBCXX_TEMPLATE_ARGS_U _U1, _U2, _U3, _U4, _U5 -#define _GLIBCXX_REF_WRAP_PARAMS ref(__a1), ref(__a2), ref(__a3), ref(__a4), ref(__a5) -#define _GLIBCXX_REF_TEMPLATE_ARGS _T1&, _T2&, _T3&, _T4&, _T5& -#define _GLIBCXX_NUM_ARGS_PLUS_1 6 -#define _GLIBCXX_T_NUM_ARGS_PLUS_1 _T6 -#include _GLIBCXX_REPEAT_HEADER -#undef _GLIBCXX_T_NUM_ARGS_PLUS_1 -#undef _GLIBCXX_NUM_ARGS_PLUS_1 -#undef _GLIBCXX_REF_TEMPLATE_ARGS -#undef _GLIBCXX_REF_WRAP_PARAMS -#undef _GLIBCXX_TEMPLATE_ARGS_U -#undef _GLIBCXX_TEMPLATE_PARAMS_U -#undef _GLIBCXX_TEMPLATE_ARGS_STRIPPED -#undef _GLIBCXX_TEMPLATE_PARAMS_NULL_CLASS -#undef _GLIBCXX_TUPLE_ASSIGN -#undef _GLIBCXX_TUPLE_COPY_INIT -#undef _GLIBCXX_TUPLE_ADD_CREF -#undef _GLIBCXX_BIND_V_ARGS -#undef _GLIBCXX_BIND_V_TEMPLATE_ARGS -#undef _GLIBCXX_MU_GET_TUPLE_ARGS -#undef _GLIBCXX_BIND_MEMBERS_INIT -#undef _GLIBCXX_BIND_MEMBERS -#undef _GLIBCXX_ARGS_SHIFTED -#undef _GLIBCXX_PARAMS_SHIFTED -#undef _GLIBCXX_TEMPLATE_ARGS_SHIFTED -#undef _GLIBCXX_TEMPLATE_PARAMS_SHIFTED -#undef _GLIBCXX_COMMA_SHIFTED -#undef _GLIBCXX_ARGS -#undef _GLIBCXX_REF_PARAMS -#undef _GLIBCXX_PARAMS -#undef _GLIBCXX_TEMPLATE_ARGS -#undef _GLIBCXX_TEMPLATE_PARAMS -#undef _GLIBCXX_COMMA -#undef _GLIBCXX_NUM_ARGS -#define _GLIBCXX_NUM_ARGS 6 -#define _GLIBCXX_COMMA , -#define _GLIBCXX_TEMPLATE_PARAMS typename _T1, typename _T2, typename _T3, typename _T4, typename _T5, typename _T6 -#define _GLIBCXX_TEMPLATE_ARGS _T1, _T2, _T3, _T4, _T5, _T6 -#define _GLIBCXX_PARAMS _T1 __a1, _T2 __a2, _T3 __a3, _T4 __a4, _T5 __a5, _T6 __a6 -#define _GLIBCXX_REF_PARAMS _T1& __a1, _T2& __a2, _T3& __a3, _T4& __a4, _T5& __a5, _T6& __a6 -#define _GLIBCXX_ARGS __a1, __a2, __a3, __a4, __a5, __a6 -#define _GLIBCXX_COMMA_SHIFTED , -#define _GLIBCXX_TEMPLATE_PARAMS_SHIFTED typename _T1, typename _T2, typename _T3, typename _T4, typename _T5 -#define _GLIBCXX_TEMPLATE_ARGS_SHIFTED _T1, _T2, _T3, _T4, _T5 -#define _GLIBCXX_PARAMS_SHIFTED _T1 __a1, _T2 __a2, _T3 __a3, _T4 __a4, _T5 __a5 -#define _GLIBCXX_ARGS_SHIFTED __a1, __a2, __a3, __a4, __a5 -#define _GLIBCXX_BIND_MEMBERS _T1 _M_arg1; _T2 _M_arg2; _T3 _M_arg3; _T4 _M_arg4; _T5 _M_arg5; _T6 _M_arg6; -#define _GLIBCXX_BIND_MEMBERS_INIT _M_arg1(__a1), _M_arg2(__a2), _M_arg3(__a3), _M_arg4(__a4), _M_arg5(__a5), _M_arg6(__a6) -#define _GLIBCXX_MU_GET_TUPLE_ARGS ::std::_GLIBCXX_TR1::get<0>(__tuple), ::std::_GLIBCXX_TR1::get<1>(__tuple), ::std::_GLIBCXX_TR1::get<2>(__tuple), ::std::_GLIBCXX_TR1::get<3>(__tuple), ::std::_GLIBCXX_TR1::get<4>(__tuple), ::std::_GLIBCXX_TR1::get<5>(__tuple) -#define _GLIBCXX_BIND_V_TEMPLATE_ARGS(_CV) typename result_of<_Mu<_T1> _CV(_T1, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T2> _CV(_T2, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T3> _CV(_T3, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T4> _CV(_T4, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T5> _CV(_T5, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T6> _CV(_T6, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type -#define _GLIBCXX_BIND_V_ARGS _Mu<_T1>()(_M_arg1, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T2>()(_M_arg2, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T3>()(_M_arg3, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T4>()(_M_arg4, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T5>()(_M_arg5, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T6>()(_M_arg6, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)) -#define _GLIBCXX_TUPLE_ADD_CREF typename __add_c_ref<_T1>::type __a1, typename __add_c_ref<_T2>::type __a2, typename __add_c_ref<_T3>::type __a3, typename __add_c_ref<_T4>::type __a4, typename __add_c_ref<_T5>::type __a5, typename __add_c_ref<_T6>::type __a6 -#define _GLIBCXX_TUPLE_COPY_INIT _M_arg1(__in._M_arg1), _M_arg2(__in._M_arg2), _M_arg3(__in._M_arg3), _M_arg4(__in._M_arg4), _M_arg5(__in._M_arg5), _M_arg6(__in._M_arg6) -#define _GLIBCXX_TUPLE_ASSIGN _M_arg1 = __in._M_arg1; _M_arg2 = __in._M_arg2; _M_arg3 = __in._M_arg3; _M_arg4 = __in._M_arg4; _M_arg5 = __in._M_arg5; _M_arg6 = __in._M_arg6; -#define _GLIBCXX_TEMPLATE_PARAMS_NULL_CLASS typename _T1 = _NullClass, typename _T2 = _NullClass, typename _T3 = _NullClass, typename _T4 = _NullClass, typename _T5 = _NullClass, typename _T6 = _NullClass -#define _GLIBCXX_TEMPLATE_ARGS_STRIPPED typename __strip_reference_wrapper<_T1>::__type, typename __strip_reference_wrapper<_T2>::__type, typename __strip_reference_wrapper<_T3>::__type, typename __strip_reference_wrapper<_T4>::__type, typename __strip_reference_wrapper<_T5>::__type, typename __strip_reference_wrapper<_T6>::__type -#define _GLIBCXX_TEMPLATE_PARAMS_U typename _U1, typename _U2, typename _U3, typename _U4, typename _U5, typename _U6 -#define _GLIBCXX_TEMPLATE_ARGS_U _U1, _U2, _U3, _U4, _U5, _U6 -#define _GLIBCXX_REF_WRAP_PARAMS ref(__a1), ref(__a2), ref(__a3), ref(__a4), ref(__a5), ref(__a6) -#define _GLIBCXX_REF_TEMPLATE_ARGS _T1&, _T2&, _T3&, _T4&, _T5&, _T6& -#define _GLIBCXX_NUM_ARGS_PLUS_1 7 -#define _GLIBCXX_T_NUM_ARGS_PLUS_1 _T7 -#include _GLIBCXX_REPEAT_HEADER -#undef _GLIBCXX_T_NUM_ARGS_PLUS_1 -#undef _GLIBCXX_NUM_ARGS_PLUS_1 -#undef _GLIBCXX_REF_TEMPLATE_ARGS -#undef _GLIBCXX_REF_WRAP_PARAMS -#undef _GLIBCXX_TEMPLATE_ARGS_U -#undef _GLIBCXX_TEMPLATE_PARAMS_U -#undef _GLIBCXX_TEMPLATE_ARGS_STRIPPED -#undef _GLIBCXX_TEMPLATE_PARAMS_NULL_CLASS -#undef _GLIBCXX_TUPLE_ASSIGN -#undef _GLIBCXX_TUPLE_COPY_INIT -#undef _GLIBCXX_TUPLE_ADD_CREF -#undef _GLIBCXX_BIND_V_ARGS -#undef _GLIBCXX_BIND_V_TEMPLATE_ARGS -#undef _GLIBCXX_MU_GET_TUPLE_ARGS -#undef _GLIBCXX_BIND_MEMBERS_INIT -#undef _GLIBCXX_BIND_MEMBERS -#undef _GLIBCXX_ARGS_SHIFTED -#undef _GLIBCXX_PARAMS_SHIFTED -#undef _GLIBCXX_TEMPLATE_ARGS_SHIFTED -#undef _GLIBCXX_TEMPLATE_PARAMS_SHIFTED -#undef _GLIBCXX_COMMA_SHIFTED -#undef _GLIBCXX_ARGS -#undef _GLIBCXX_REF_PARAMS -#undef _GLIBCXX_PARAMS -#undef _GLIBCXX_TEMPLATE_ARGS -#undef _GLIBCXX_TEMPLATE_PARAMS -#undef _GLIBCXX_COMMA -#undef _GLIBCXX_NUM_ARGS -#define _GLIBCXX_NUM_ARGS 7 -#define _GLIBCXX_COMMA , -#define _GLIBCXX_TEMPLATE_PARAMS typename _T1, typename _T2, typename _T3, typename _T4, typename _T5, typename _T6, typename _T7 -#define _GLIBCXX_TEMPLATE_ARGS _T1, _T2, _T3, _T4, _T5, _T6, _T7 -#define _GLIBCXX_PARAMS _T1 __a1, _T2 __a2, _T3 __a3, _T4 __a4, _T5 __a5, _T6 __a6, _T7 __a7 -#define _GLIBCXX_REF_PARAMS _T1& __a1, _T2& __a2, _T3& __a3, _T4& __a4, _T5& __a5, _T6& __a6, _T7& __a7 -#define _GLIBCXX_ARGS __a1, __a2, __a3, __a4, __a5, __a6, __a7 -#define _GLIBCXX_COMMA_SHIFTED , -#define _GLIBCXX_TEMPLATE_PARAMS_SHIFTED typename _T1, typename _T2, typename _T3, typename _T4, typename _T5, typename _T6 -#define _GLIBCXX_TEMPLATE_ARGS_SHIFTED _T1, _T2, _T3, _T4, _T5, _T6 -#define _GLIBCXX_PARAMS_SHIFTED _T1 __a1, _T2 __a2, _T3 __a3, _T4 __a4, _T5 __a5, _T6 __a6 -#define _GLIBCXX_ARGS_SHIFTED __a1, __a2, __a3, __a4, __a5, __a6 -#define _GLIBCXX_BIND_MEMBERS _T1 _M_arg1; _T2 _M_arg2; _T3 _M_arg3; _T4 _M_arg4; _T5 _M_arg5; _T6 _M_arg6; _T7 _M_arg7; -#define _GLIBCXX_BIND_MEMBERS_INIT _M_arg1(__a1), _M_arg2(__a2), _M_arg3(__a3), _M_arg4(__a4), _M_arg5(__a5), _M_arg6(__a6), _M_arg7(__a7) -#define _GLIBCXX_MU_GET_TUPLE_ARGS ::std::_GLIBCXX_TR1::get<0>(__tuple), ::std::_GLIBCXX_TR1::get<1>(__tuple), ::std::_GLIBCXX_TR1::get<2>(__tuple), ::std::_GLIBCXX_TR1::get<3>(__tuple), ::std::_GLIBCXX_TR1::get<4>(__tuple), ::std::_GLIBCXX_TR1::get<5>(__tuple), ::std::_GLIBCXX_TR1::get<6>(__tuple) -#define _GLIBCXX_BIND_V_TEMPLATE_ARGS(_CV) typename result_of<_Mu<_T1> _CV(_T1, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T2> _CV(_T2, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T3> _CV(_T3, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T4> _CV(_T4, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T5> _CV(_T5, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T6> _CV(_T6, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T7> _CV(_T7, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type -#define _GLIBCXX_BIND_V_ARGS _Mu<_T1>()(_M_arg1, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T2>()(_M_arg2, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T3>()(_M_arg3, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T4>()(_M_arg4, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T5>()(_M_arg5, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T6>()(_M_arg6, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T7>()(_M_arg7, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)) -#define _GLIBCXX_TUPLE_ADD_CREF typename __add_c_ref<_T1>::type __a1, typename __add_c_ref<_T2>::type __a2, typename __add_c_ref<_T3>::type __a3, typename __add_c_ref<_T4>::type __a4, typename __add_c_ref<_T5>::type __a5, typename __add_c_ref<_T6>::type __a6, typename __add_c_ref<_T7>::type __a7 -#define _GLIBCXX_TUPLE_COPY_INIT _M_arg1(__in._M_arg1), _M_arg2(__in._M_arg2), _M_arg3(__in._M_arg3), _M_arg4(__in._M_arg4), _M_arg5(__in._M_arg5), _M_arg6(__in._M_arg6), _M_arg7(__in._M_arg7) -#define _GLIBCXX_TUPLE_ASSIGN _M_arg1 = __in._M_arg1; _M_arg2 = __in._M_arg2; _M_arg3 = __in._M_arg3; _M_arg4 = __in._M_arg4; _M_arg5 = __in._M_arg5; _M_arg6 = __in._M_arg6; _M_arg7 = __in._M_arg7; -#define _GLIBCXX_TEMPLATE_PARAMS_NULL_CLASS typename _T1 = _NullClass, typename _T2 = _NullClass, typename _T3 = _NullClass, typename _T4 = _NullClass, typename _T5 = _NullClass, typename _T6 = _NullClass, typename _T7 = _NullClass -#define _GLIBCXX_TEMPLATE_ARGS_STRIPPED typename __strip_reference_wrapper<_T1>::__type, typename __strip_reference_wrapper<_T2>::__type, typename __strip_reference_wrapper<_T3>::__type, typename __strip_reference_wrapper<_T4>::__type, typename __strip_reference_wrapper<_T5>::__type, typename __strip_reference_wrapper<_T6>::__type, typename __strip_reference_wrapper<_T7>::__type -#define _GLIBCXX_TEMPLATE_PARAMS_U typename _U1, typename _U2, typename _U3, typename _U4, typename _U5, typename _U6, typename _U7 -#define _GLIBCXX_TEMPLATE_ARGS_U _U1, _U2, _U3, _U4, _U5, _U6, _U7 -#define _GLIBCXX_REF_WRAP_PARAMS ref(__a1), ref(__a2), ref(__a3), ref(__a4), ref(__a5), ref(__a6), ref(__a7) -#define _GLIBCXX_REF_TEMPLATE_ARGS _T1&, _T2&, _T3&, _T4&, _T5&, _T6&, _T7& -#define _GLIBCXX_NUM_ARGS_PLUS_1 8 -#define _GLIBCXX_T_NUM_ARGS_PLUS_1 _T8 -#include _GLIBCXX_REPEAT_HEADER -#undef _GLIBCXX_T_NUM_ARGS_PLUS_1 -#undef _GLIBCXX_NUM_ARGS_PLUS_1 -#undef _GLIBCXX_REF_TEMPLATE_ARGS -#undef _GLIBCXX_REF_WRAP_PARAMS -#undef _GLIBCXX_TEMPLATE_ARGS_U -#undef _GLIBCXX_TEMPLATE_PARAMS_U -#undef _GLIBCXX_TEMPLATE_ARGS_STRIPPED -#undef _GLIBCXX_TEMPLATE_PARAMS_NULL_CLASS -#undef _GLIBCXX_TUPLE_ASSIGN -#undef _GLIBCXX_TUPLE_COPY_INIT -#undef _GLIBCXX_TUPLE_ADD_CREF -#undef _GLIBCXX_BIND_V_ARGS -#undef _GLIBCXX_BIND_V_TEMPLATE_ARGS -#undef _GLIBCXX_MU_GET_TUPLE_ARGS -#undef _GLIBCXX_BIND_MEMBERS_INIT -#undef _GLIBCXX_BIND_MEMBERS -#undef _GLIBCXX_ARGS_SHIFTED -#undef _GLIBCXX_PARAMS_SHIFTED -#undef _GLIBCXX_TEMPLATE_ARGS_SHIFTED -#undef _GLIBCXX_TEMPLATE_PARAMS_SHIFTED -#undef _GLIBCXX_COMMA_SHIFTED -#undef _GLIBCXX_ARGS -#undef _GLIBCXX_REF_PARAMS -#undef _GLIBCXX_PARAMS -#undef _GLIBCXX_TEMPLATE_ARGS -#undef _GLIBCXX_TEMPLATE_PARAMS -#undef _GLIBCXX_COMMA -#undef _GLIBCXX_NUM_ARGS -#define _GLIBCXX_NUM_ARGS 8 -#define _GLIBCXX_COMMA , -#define _GLIBCXX_TEMPLATE_PARAMS typename _T1, typename _T2, typename _T3, typename _T4, typename _T5, typename _T6, typename _T7, typename _T8 -#define _GLIBCXX_TEMPLATE_ARGS _T1, _T2, _T3, _T4, _T5, _T6, _T7, _T8 -#define _GLIBCXX_PARAMS _T1 __a1, _T2 __a2, _T3 __a3, _T4 __a4, _T5 __a5, _T6 __a6, _T7 __a7, _T8 __a8 -#define _GLIBCXX_REF_PARAMS _T1& __a1, _T2& __a2, _T3& __a3, _T4& __a4, _T5& __a5, _T6& __a6, _T7& __a7, _T8& __a8 -#define _GLIBCXX_ARGS __a1, __a2, __a3, __a4, __a5, __a6, __a7, __a8 -#define _GLIBCXX_COMMA_SHIFTED , -#define _GLIBCXX_TEMPLATE_PARAMS_SHIFTED typename _T1, typename _T2, typename _T3, typename _T4, typename _T5, typename _T6, typename _T7 -#define _GLIBCXX_TEMPLATE_ARGS_SHIFTED _T1, _T2, _T3, _T4, _T5, _T6, _T7 -#define _GLIBCXX_PARAMS_SHIFTED _T1 __a1, _T2 __a2, _T3 __a3, _T4 __a4, _T5 __a5, _T6 __a6, _T7 __a7 -#define _GLIBCXX_ARGS_SHIFTED __a1, __a2, __a3, __a4, __a5, __a6, __a7 -#define _GLIBCXX_BIND_MEMBERS _T1 _M_arg1; _T2 _M_arg2; _T3 _M_arg3; _T4 _M_arg4; _T5 _M_arg5; _T6 _M_arg6; _T7 _M_arg7; _T8 _M_arg8; -#define _GLIBCXX_BIND_MEMBERS_INIT _M_arg1(__a1), _M_arg2(__a2), _M_arg3(__a3), _M_arg4(__a4), _M_arg5(__a5), _M_arg6(__a6), _M_arg7(__a7), _M_arg8(__a8) -#define _GLIBCXX_MU_GET_TUPLE_ARGS ::std::_GLIBCXX_TR1::get<0>(__tuple), ::std::_GLIBCXX_TR1::get<1>(__tuple), ::std::_GLIBCXX_TR1::get<2>(__tuple), ::std::_GLIBCXX_TR1::get<3>(__tuple), ::std::_GLIBCXX_TR1::get<4>(__tuple), ::std::_GLIBCXX_TR1::get<5>(__tuple), ::std::_GLIBCXX_TR1::get<6>(__tuple), ::std::_GLIBCXX_TR1::get<7>(__tuple) -#define _GLIBCXX_BIND_V_TEMPLATE_ARGS(_CV) typename result_of<_Mu<_T1> _CV(_T1, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T2> _CV(_T2, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T3> _CV(_T3, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T4> _CV(_T4, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T5> _CV(_T5, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T6> _CV(_T6, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T7> _CV(_T7, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T8> _CV(_T8, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type -#define _GLIBCXX_BIND_V_ARGS _Mu<_T1>()(_M_arg1, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T2>()(_M_arg2, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T3>()(_M_arg3, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T4>()(_M_arg4, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T5>()(_M_arg5, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T6>()(_M_arg6, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T7>()(_M_arg7, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T8>()(_M_arg8, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)) -#define _GLIBCXX_TUPLE_ADD_CREF typename __add_c_ref<_T1>::type __a1, typename __add_c_ref<_T2>::type __a2, typename __add_c_ref<_T3>::type __a3, typename __add_c_ref<_T4>::type __a4, typename __add_c_ref<_T5>::type __a5, typename __add_c_ref<_T6>::type __a6, typename __add_c_ref<_T7>::type __a7, typename __add_c_ref<_T8>::type __a8 -#define _GLIBCXX_TUPLE_COPY_INIT _M_arg1(__in._M_arg1), _M_arg2(__in._M_arg2), _M_arg3(__in._M_arg3), _M_arg4(__in._M_arg4), _M_arg5(__in._M_arg5), _M_arg6(__in._M_arg6), _M_arg7(__in._M_arg7), _M_arg8(__in._M_arg8) -#define _GLIBCXX_TUPLE_ASSIGN _M_arg1 = __in._M_arg1; _M_arg2 = __in._M_arg2; _M_arg3 = __in._M_arg3; _M_arg4 = __in._M_arg4; _M_arg5 = __in._M_arg5; _M_arg6 = __in._M_arg6; _M_arg7 = __in._M_arg7; _M_arg8 = __in._M_arg8; -#define _GLIBCXX_TEMPLATE_PARAMS_NULL_CLASS typename _T1 = _NullClass, typename _T2 = _NullClass, typename _T3 = _NullClass, typename _T4 = _NullClass, typename _T5 = _NullClass, typename _T6 = _NullClass, typename _T7 = _NullClass, typename _T8 = _NullClass -#define _GLIBCXX_TEMPLATE_ARGS_STRIPPED typename __strip_reference_wrapper<_T1>::__type, typename __strip_reference_wrapper<_T2>::__type, typename __strip_reference_wrapper<_T3>::__type, typename __strip_reference_wrapper<_T4>::__type, typename __strip_reference_wrapper<_T5>::__type, typename __strip_reference_wrapper<_T6>::__type, typename __strip_reference_wrapper<_T7>::__type, typename __strip_reference_wrapper<_T8>::__type -#define _GLIBCXX_TEMPLATE_PARAMS_U typename _U1, typename _U2, typename _U3, typename _U4, typename _U5, typename _U6, typename _U7, typename _U8 -#define _GLIBCXX_TEMPLATE_ARGS_U _U1, _U2, _U3, _U4, _U5, _U6, _U7, _U8 -#define _GLIBCXX_REF_WRAP_PARAMS ref(__a1), ref(__a2), ref(__a3), ref(__a4), ref(__a5), ref(__a6), ref(__a7), ref(__a8) -#define _GLIBCXX_REF_TEMPLATE_ARGS _T1&, _T2&, _T3&, _T4&, _T5&, _T6&, _T7&, _T8& -#define _GLIBCXX_NUM_ARGS_PLUS_1 9 -#define _GLIBCXX_T_NUM_ARGS_PLUS_1 _T9 -#include _GLIBCXX_REPEAT_HEADER -#undef _GLIBCXX_T_NUM_ARGS_PLUS_1 -#undef _GLIBCXX_NUM_ARGS_PLUS_1 -#undef _GLIBCXX_REF_TEMPLATE_ARGS -#undef _GLIBCXX_REF_WRAP_PARAMS -#undef _GLIBCXX_TEMPLATE_ARGS_U -#undef _GLIBCXX_TEMPLATE_PARAMS_U -#undef _GLIBCXX_TEMPLATE_ARGS_STRIPPED -#undef _GLIBCXX_TEMPLATE_PARAMS_NULL_CLASS -#undef _GLIBCXX_TUPLE_ASSIGN -#undef _GLIBCXX_TUPLE_COPY_INIT -#undef _GLIBCXX_TUPLE_ADD_CREF -#undef _GLIBCXX_BIND_V_ARGS -#undef _GLIBCXX_BIND_V_TEMPLATE_ARGS -#undef _GLIBCXX_MU_GET_TUPLE_ARGS -#undef _GLIBCXX_BIND_MEMBERS_INIT -#undef _GLIBCXX_BIND_MEMBERS -#undef _GLIBCXX_ARGS_SHIFTED -#undef _GLIBCXX_PARAMS_SHIFTED -#undef _GLIBCXX_TEMPLATE_ARGS_SHIFTED -#undef _GLIBCXX_TEMPLATE_PARAMS_SHIFTED -#undef _GLIBCXX_COMMA_SHIFTED -#undef _GLIBCXX_ARGS -#undef _GLIBCXX_REF_PARAMS -#undef _GLIBCXX_PARAMS -#undef _GLIBCXX_TEMPLATE_ARGS -#undef _GLIBCXX_TEMPLATE_PARAMS -#undef _GLIBCXX_COMMA -#undef _GLIBCXX_NUM_ARGS -#define _GLIBCXX_NUM_ARGS 9 -#define _GLIBCXX_COMMA , -#define _GLIBCXX_TEMPLATE_PARAMS typename _T1, typename _T2, typename _T3, typename _T4, typename _T5, typename _T6, typename _T7, typename _T8, typename _T9 -#define _GLIBCXX_TEMPLATE_ARGS _T1, _T2, _T3, _T4, _T5, _T6, _T7, _T8, _T9 -#define _GLIBCXX_PARAMS _T1 __a1, _T2 __a2, _T3 __a3, _T4 __a4, _T5 __a5, _T6 __a6, _T7 __a7, _T8 __a8, _T9 __a9 -#define _GLIBCXX_REF_PARAMS _T1& __a1, _T2& __a2, _T3& __a3, _T4& __a4, _T5& __a5, _T6& __a6, _T7& __a7, _T8& __a8, _T9& __a9 -#define _GLIBCXX_ARGS __a1, __a2, __a3, __a4, __a5, __a6, __a7, __a8, __a9 -#define _GLIBCXX_COMMA_SHIFTED , -#define _GLIBCXX_TEMPLATE_PARAMS_SHIFTED typename _T1, typename _T2, typename _T3, typename _T4, typename _T5, typename _T6, typename _T7, typename _T8 -#define _GLIBCXX_TEMPLATE_ARGS_SHIFTED _T1, _T2, _T3, _T4, _T5, _T6, _T7, _T8 -#define _GLIBCXX_PARAMS_SHIFTED _T1 __a1, _T2 __a2, _T3 __a3, _T4 __a4, _T5 __a5, _T6 __a6, _T7 __a7, _T8 __a8 -#define _GLIBCXX_ARGS_SHIFTED __a1, __a2, __a3, __a4, __a5, __a6, __a7, __a8 -#define _GLIBCXX_BIND_MEMBERS _T1 _M_arg1; _T2 _M_arg2; _T3 _M_arg3; _T4 _M_arg4; _T5 _M_arg5; _T6 _M_arg6; _T7 _M_arg7; _T8 _M_arg8; _T9 _M_arg9; -#define _GLIBCXX_BIND_MEMBERS_INIT _M_arg1(__a1), _M_arg2(__a2), _M_arg3(__a3), _M_arg4(__a4), _M_arg5(__a5), _M_arg6(__a6), _M_arg7(__a7), _M_arg8(__a8), _M_arg9(__a9) -#define _GLIBCXX_MU_GET_TUPLE_ARGS ::std::_GLIBCXX_TR1::get<0>(__tuple), ::std::_GLIBCXX_TR1::get<1>(__tuple), ::std::_GLIBCXX_TR1::get<2>(__tuple), ::std::_GLIBCXX_TR1::get<3>(__tuple), ::std::_GLIBCXX_TR1::get<4>(__tuple), ::std::_GLIBCXX_TR1::get<5>(__tuple), ::std::_GLIBCXX_TR1::get<6>(__tuple), ::std::_GLIBCXX_TR1::get<7>(__tuple), ::std::_GLIBCXX_TR1::get<8>(__tuple) -#define _GLIBCXX_BIND_V_TEMPLATE_ARGS(_CV) typename result_of<_Mu<_T1> _CV(_T1, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T2> _CV(_T2, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T3> _CV(_T3, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T4> _CV(_T4, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T5> _CV(_T5, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T6> _CV(_T6, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T7> _CV(_T7, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T8> _CV(_T8, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T9> _CV(_T9, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type -#define _GLIBCXX_BIND_V_ARGS _Mu<_T1>()(_M_arg1, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T2>()(_M_arg2, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T3>()(_M_arg3, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T4>()(_M_arg4, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T5>()(_M_arg5, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T6>()(_M_arg6, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T7>()(_M_arg7, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T8>()(_M_arg8, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T9>()(_M_arg9, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)) -#define _GLIBCXX_TUPLE_ADD_CREF typename __add_c_ref<_T1>::type __a1, typename __add_c_ref<_T2>::type __a2, typename __add_c_ref<_T3>::type __a3, typename __add_c_ref<_T4>::type __a4, typename __add_c_ref<_T5>::type __a5, typename __add_c_ref<_T6>::type __a6, typename __add_c_ref<_T7>::type __a7, typename __add_c_ref<_T8>::type __a8, typename __add_c_ref<_T9>::type __a9 -#define _GLIBCXX_TUPLE_COPY_INIT _M_arg1(__in._M_arg1), _M_arg2(__in._M_arg2), _M_arg3(__in._M_arg3), _M_arg4(__in._M_arg4), _M_arg5(__in._M_arg5), _M_arg6(__in._M_arg6), _M_arg7(__in._M_arg7), _M_arg8(__in._M_arg8), _M_arg9(__in._M_arg9) -#define _GLIBCXX_TUPLE_ASSIGN _M_arg1 = __in._M_arg1; _M_arg2 = __in._M_arg2; _M_arg3 = __in._M_arg3; _M_arg4 = __in._M_arg4; _M_arg5 = __in._M_arg5; _M_arg6 = __in._M_arg6; _M_arg7 = __in._M_arg7; _M_arg8 = __in._M_arg8; _M_arg9 = __in._M_arg9; -#define _GLIBCXX_TEMPLATE_PARAMS_NULL_CLASS typename _T1 = _NullClass, typename _T2 = _NullClass, typename _T3 = _NullClass, typename _T4 = _NullClass, typename _T5 = _NullClass, typename _T6 = _NullClass, typename _T7 = _NullClass, typename _T8 = _NullClass, typename _T9 = _NullClass -#define _GLIBCXX_TEMPLATE_ARGS_STRIPPED typename __strip_reference_wrapper<_T1>::__type, typename __strip_reference_wrapper<_T2>::__type, typename __strip_reference_wrapper<_T3>::__type, typename __strip_reference_wrapper<_T4>::__type, typename __strip_reference_wrapper<_T5>::__type, typename __strip_reference_wrapper<_T6>::__type, typename __strip_reference_wrapper<_T7>::__type, typename __strip_reference_wrapper<_T8>::__type, typename __strip_reference_wrapper<_T9>::__type -#define _GLIBCXX_TEMPLATE_PARAMS_U typename _U1, typename _U2, typename _U3, typename _U4, typename _U5, typename _U6, typename _U7, typename _U8, typename _U9 -#define _GLIBCXX_TEMPLATE_ARGS_U _U1, _U2, _U3, _U4, _U5, _U6, _U7, _U8, _U9 -#define _GLIBCXX_REF_WRAP_PARAMS ref(__a1), ref(__a2), ref(__a3), ref(__a4), ref(__a5), ref(__a6), ref(__a7), ref(__a8), ref(__a9) -#define _GLIBCXX_REF_TEMPLATE_ARGS _T1&, _T2&, _T3&, _T4&, _T5&, _T6&, _T7&, _T8&, _T9& -#define _GLIBCXX_NUM_ARGS_PLUS_1 10 -#define _GLIBCXX_T_NUM_ARGS_PLUS_1 _T10 -#include _GLIBCXX_REPEAT_HEADER -#undef _GLIBCXX_T_NUM_ARGS_PLUS_1 -#undef _GLIBCXX_NUM_ARGS_PLUS_1 -#undef _GLIBCXX_REF_TEMPLATE_ARGS -#undef _GLIBCXX_REF_WRAP_PARAMS -#undef _GLIBCXX_TEMPLATE_ARGS_U -#undef _GLIBCXX_TEMPLATE_PARAMS_U -#undef _GLIBCXX_TEMPLATE_ARGS_STRIPPED -#undef _GLIBCXX_TEMPLATE_PARAMS_NULL_CLASS -#undef _GLIBCXX_TUPLE_ASSIGN -#undef _GLIBCXX_TUPLE_COPY_INIT -#undef _GLIBCXX_TUPLE_ADD_CREF -#undef _GLIBCXX_BIND_V_ARGS -#undef _GLIBCXX_BIND_V_TEMPLATE_ARGS -#undef _GLIBCXX_MU_GET_TUPLE_ARGS -#undef _GLIBCXX_BIND_MEMBERS_INIT -#undef _GLIBCXX_BIND_MEMBERS -#undef _GLIBCXX_ARGS_SHIFTED -#undef _GLIBCXX_PARAMS_SHIFTED -#undef _GLIBCXX_TEMPLATE_ARGS_SHIFTED -#undef _GLIBCXX_TEMPLATE_PARAMS_SHIFTED -#undef _GLIBCXX_COMMA_SHIFTED -#undef _GLIBCXX_ARGS -#undef _GLIBCXX_REF_PARAMS -#undef _GLIBCXX_PARAMS -#undef _GLIBCXX_TEMPLATE_ARGS -#undef _GLIBCXX_TEMPLATE_PARAMS -#undef _GLIBCXX_COMMA -#undef _GLIBCXX_NUM_ARGS -#define _GLIBCXX_LAST_INCLUDE -#define _GLIBCXX_NUM_ARGS 10 -#define _GLIBCXX_COMMA , -#define _GLIBCXX_TEMPLATE_PARAMS typename _T1, typename _T2, typename _T3, typename _T4, typename _T5, typename _T6, typename _T7, typename _T8, typename _T9, typename _T10 -#define _GLIBCXX_TEMPLATE_ARGS _T1, _T2, _T3, _T4, _T5, _T6, _T7, _T8, _T9, _T10 -#define _GLIBCXX_PARAMS _T1 __a1, _T2 __a2, _T3 __a3, _T4 __a4, _T5 __a5, _T6 __a6, _T7 __a7, _T8 __a8, _T9 __a9, _T10 __a10 -#define _GLIBCXX_REF_PARAMS _T1& __a1, _T2& __a2, _T3& __a3, _T4& __a4, _T5& __a5, _T6& __a6, _T7& __a7, _T8& __a8, _T9& __a9, _T10& __a10 -#define _GLIBCXX_ARGS __a1, __a2, __a3, __a4, __a5, __a6, __a7, __a8, __a9, __a10 -#define _GLIBCXX_COMMA_SHIFTED , -#define _GLIBCXX_TEMPLATE_PARAMS_SHIFTED typename _T1, typename _T2, typename _T3, typename _T4, typename _T5, typename _T6, typename _T7, typename _T8, typename _T9 -#define _GLIBCXX_TEMPLATE_ARGS_SHIFTED _T1, _T2, _T3, _T4, _T5, _T6, _T7, _T8, _T9 -#define _GLIBCXX_PARAMS_SHIFTED _T1 __a1, _T2 __a2, _T3 __a3, _T4 __a4, _T5 __a5, _T6 __a6, _T7 __a7, _T8 __a8, _T9 __a9 -#define _GLIBCXX_ARGS_SHIFTED __a1, __a2, __a3, __a4, __a5, __a6, __a7, __a8, __a9 -#define _GLIBCXX_BIND_MEMBERS _T1 _M_arg1; _T2 _M_arg2; _T3 _M_arg3; _T4 _M_arg4; _T5 _M_arg5; _T6 _M_arg6; _T7 _M_arg7; _T8 _M_arg8; _T9 _M_arg9; _T10 _M_arg10; -#define _GLIBCXX_BIND_MEMBERS_INIT _M_arg1(__a1), _M_arg2(__a2), _M_arg3(__a3), _M_arg4(__a4), _M_arg5(__a5), _M_arg6(__a6), _M_arg7(__a7), _M_arg8(__a8), _M_arg9(__a9), _M_arg10(__a10) -#define _GLIBCXX_MU_GET_TUPLE_ARGS ::std::_GLIBCXX_TR1::get<0>(__tuple), ::std::_GLIBCXX_TR1::get<1>(__tuple), ::std::_GLIBCXX_TR1::get<2>(__tuple), ::std::_GLIBCXX_TR1::get<3>(__tuple), ::std::_GLIBCXX_TR1::get<4>(__tuple), ::std::_GLIBCXX_TR1::get<5>(__tuple), ::std::_GLIBCXX_TR1::get<6>(__tuple), ::std::_GLIBCXX_TR1::get<7>(__tuple), ::std::_GLIBCXX_TR1::get<8>(__tuple), ::std::_GLIBCXX_TR1::get<9>(__tuple) -#define _GLIBCXX_BIND_V_TEMPLATE_ARGS(_CV) typename result_of<_Mu<_T1> _CV(_T1, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T2> _CV(_T2, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T3> _CV(_T3, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T4> _CV(_T4, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T5> _CV(_T5, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T6> _CV(_T6, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T7> _CV(_T7, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T8> _CV(_T8, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T9> _CV(_T9, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type, typename result_of<_Mu<_T10> _CV(_T10, tuple<_GLIBCXX_BIND_TEMPLATE_ARGS>)>::type -#define _GLIBCXX_BIND_V_ARGS _Mu<_T1>()(_M_arg1, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T2>()(_M_arg2, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T3>()(_M_arg3, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T4>()(_M_arg4, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T5>()(_M_arg5, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T6>()(_M_arg6, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T7>()(_M_arg7, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T8>()(_M_arg8, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T9>()(_M_arg9, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)), _Mu<_T10>()(_M_arg10, ::std::_GLIBCXX_TR1::tie(_GLIBCXX_BIND_ARGS)) -#define _GLIBCXX_TUPLE_ADD_CREF typename __add_c_ref<_T1>::type __a1, typename __add_c_ref<_T2>::type __a2, typename __add_c_ref<_T3>::type __a3, typename __add_c_ref<_T4>::type __a4, typename __add_c_ref<_T5>::type __a5, typename __add_c_ref<_T6>::type __a6, typename __add_c_ref<_T7>::type __a7, typename __add_c_ref<_T8>::type __a8, typename __add_c_ref<_T9>::type __a9, typename __add_c_ref<_T10>::type __a10 -#define _GLIBCXX_TUPLE_COPY_INIT _M_arg1(__in._M_arg1), _M_arg2(__in._M_arg2), _M_arg3(__in._M_arg3), _M_arg4(__in._M_arg4), _M_arg5(__in._M_arg5), _M_arg6(__in._M_arg6), _M_arg7(__in._M_arg7), _M_arg8(__in._M_arg8), _M_arg9(__in._M_arg9), _M_arg10(__in._M_arg10) -#define _GLIBCXX_TUPLE_ASSIGN _M_arg1 = __in._M_arg1; _M_arg2 = __in._M_arg2; _M_arg3 = __in._M_arg3; _M_arg4 = __in._M_arg4; _M_arg5 = __in._M_arg5; _M_arg6 = __in._M_arg6; _M_arg7 = __in._M_arg7; _M_arg8 = __in._M_arg8; _M_arg9 = __in._M_arg9; _M_arg10 = __in._M_arg10; -#define _GLIBCXX_TEMPLATE_PARAMS_NULL_CLASS typename _T1 = _NullClass, typename _T2 = _NullClass, typename _T3 = _NullClass, typename _T4 = _NullClass, typename _T5 = _NullClass, typename _T6 = _NullClass, typename _T7 = _NullClass, typename _T8 = _NullClass, typename _T9 = _NullClass, typename _T10 = _NullClass -#define _GLIBCXX_TEMPLATE_ARGS_STRIPPED typename __strip_reference_wrapper<_T1>::__type, typename __strip_reference_wrapper<_T2>::__type, typename __strip_reference_wrapper<_T3>::__type, typename __strip_reference_wrapper<_T4>::__type, typename __strip_reference_wrapper<_T5>::__type, typename __strip_reference_wrapper<_T6>::__type, typename __strip_reference_wrapper<_T7>::__type, typename __strip_reference_wrapper<_T8>::__type, typename __strip_reference_wrapper<_T9>::__type, typename __strip_reference_wrapper<_T10>::__type -#define _GLIBCXX_TEMPLATE_PARAMS_U typename _U1, typename _U2, typename _U3, typename _U4, typename _U5, typename _U6, typename _U7, typename _U8, typename _U9, typename _U10 -#define _GLIBCXX_TEMPLATE_ARGS_U _U1, _U2, _U3, _U4, _U5, _U6, _U7, _U8, _U9, _U10 -#define _GLIBCXX_REF_WRAP_PARAMS ref(__a1), ref(__a2), ref(__a3), ref(__a4), ref(__a5), ref(__a6), ref(__a7), ref(__a8), ref(__a9), ref(__a10) -#define _GLIBCXX_REF_TEMPLATE_ARGS _T1&, _T2&, _T3&, _T4&, _T5&, _T6&, _T7&, _T8&, _T9&, _T10& -#define _GLIBCXX_NUM_ARGS_PLUS_1 11 -#define _GLIBCXX_T_NUM_ARGS_PLUS_1 _T11 -#include _GLIBCXX_REPEAT_HEADER -#undef _GLIBCXX_T_NUM_ARGS_PLUS_1 -#undef _GLIBCXX_NUM_ARGS_PLUS_1 -#undef _GLIBCXX_REF_TEMPLATE_ARGS -#undef _GLIBCXX_REF_WRAP_PARAMS -#undef _GLIBCXX_TEMPLATE_ARGS_U -#undef _GLIBCXX_TEMPLATE_PARAMS_U -#undef _GLIBCXX_TEMPLATE_ARGS_STRIPPED -#undef _GLIBCXX_TEMPLATE_PARAMS_NULL_CLASS -#undef _GLIBCXX_TUPLE_ASSIGN -#undef _GLIBCXX_TUPLE_COPY_INIT -#undef _GLIBCXX_TUPLE_ADD_CREF -#undef _GLIBCXX_BIND_V_ARGS -#undef _GLIBCXX_BIND_V_TEMPLATE_ARGS -#undef _GLIBCXX_MU_GET_TUPLE_ARGS -#undef _GLIBCXX_BIND_MEMBERS_INIT -#undef _GLIBCXX_BIND_MEMBERS -#undef _GLIBCXX_ARGS_SHIFTED -#undef _GLIBCXX_PARAMS_SHIFTED -#undef _GLIBCXX_TEMPLATE_ARGS_SHIFTED -#undef _GLIBCXX_TEMPLATE_PARAMS_SHIFTED -#undef _GLIBCXX_COMMA_SHIFTED -#undef _GLIBCXX_ARGS -#undef _GLIBCXX_REF_PARAMS -#undef _GLIBCXX_PARAMS -#undef _GLIBCXX_TEMPLATE_ARGS -#undef _GLIBCXX_TEMPLATE_PARAMS -#undef _GLIBCXX_COMMA -#undef _GLIBCXX_NUM_ARGS -#undef _GLIBCXX_LAST_INCLUDE - diff --git a/libstdc++-v3/include/tr1/tuple b/libstdc++-v3/include/tr1/tuple index ea1d9e2..96ba4b8 100644 --- a/libstdc++-v3/include/tr1/tuple +++ b/libstdc++-v3/include/tr1/tuple @@ -32,29 +32,21 @@ */ // Chris Jefferson +// Variadic Templates support by Douglas Gregor #ifndef _TR1_TUPLE #define _TR1_TUPLE 1 +#pragma GCC system_header + #include #include +#include // for __enable_if namespace std { _GLIBCXX_BEGIN_NAMESPACE(_GLIBCXX_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 - struct tuple_element; - - /// Finds the size of a given tuple type. - template - struct tuple_size; - // Adds a const reference to a non-reference type. template struct __add_c_ref @@ -73,37 +65,220 @@ _GLIBCXX_BEGIN_NAMESPACE(_GLIBCXX_TR1) struct __add_ref<_Tp&> { typedef _Tp& type; }; - // Class used in the implementation of get - template - struct __get_helper; +/** + * @if maint + * Contains the actual implementation of the @c tuple template, stored + * as a recursive inheritance hierarchy from the first element (most + * derived class) to the last (least derived class). The @c Idx + * parameter gives the 0-based index of the element stored at this + * point in the hierarchy; we use it to implement a constant-time + * get() operation. + * @endif + */ + template + struct _Tuple_impl; - // Returns a const reference to the ith element of a tuple. - // Any const or non-const ref elements are returned with their original type. + /** + * @if maint + * Zero-element tuple implementation. This is the basis case for the + * inheritance recursion. + * @endif maint + */ + template + struct _Tuple_impl<_Idx> { }; - // This class helps construct the various comparison operations on tuples - template - struct __tuple_compare; + /** + * @if maint + * Recursive tuple implementation. Here we store the @c Head element + * and derive from a @c Tuple_impl containing the remaining elements + * (which contains the @c Tail). + * @endif + */ + template + struct _Tuple_impl<_Idx, _Head, _Tail...> + : public _Tuple_impl<_Idx+1, _Tail...> + { + typedef _Tuple_impl<_Idx+1, _Tail...> _Inherited; - // Helper which adds a reference to a type when given a reference_wrapper - template - struct __strip_reference_wrapper + _Head _M_head; + + _Inherited& _M_tail() { return *this; } + const _Inherited& _M_tail() const { return *this; } + + _Tuple_impl() : _Inherited(), _M_head() { } + + explicit + _Tuple_impl(typename __add_c_ref<_Head>::type __head, + typename __add_c_ref<_Tail>::type... __tail) + : _Inherited(__tail...), _M_head(__head) { } + + template + _Tuple_impl(const _Tuple_impl<_Idx, _UElements...>& __in) + : _Inherited(__in._M_tail()), _M_head(__in._M_head) { } + + _Tuple_impl(const _Tuple_impl& __in) + : _Inherited(__in._M_tail()), _M_head(__in._M_head) { } + + template + _Tuple_impl& operator=(const _Tuple_impl<_Idx, _UElements...>& __in) + { + _M_head = __in._M_head; + _M_tail() = __in._M_tail(); + return *this; + } + + _Tuple_impl& operator=(const _Tuple_impl& __in) + { + _M_head = __in._M_head; + _M_tail() = __in._M_tail(); + return *this; + } + }; + + template + class tuple : public _Tuple_impl<0, _Elements...> { - typedef _Tp __type; + typedef _Tuple_impl<0, _Elements...> _Inherited; + + public: + tuple() : _Inherited() { } + + explicit + tuple(typename __add_c_ref<_Elements>::type... __elements) + : _Inherited(__elements...) { } + + template + tuple(const tuple<_UElements...>& __in) + : _Inherited(__in) { } + + tuple(const tuple& __in) + : _Inherited(__in) { } + + template + tuple& operator=(const tuple<_UElements...>& __in) + { + static_cast<_Inherited&>(*this) = __in; + return *this; + } + + tuple& operator=(const tuple& __in) + { + static_cast<_Inherited&>(*this) = __in; + return *this; + } }; - template - struct __strip_reference_wrapper > + template<> class tuple<> { }; + + // 2-element tuple, with construction and assignment from a pair. + template + class tuple<_T1, _T2> : public _Tuple_impl<0, _T1, _T2> { - typedef _Tp& __type; + typedef _Tuple_impl<0, _T1, _T2> _Inherited; + + public: + tuple() : _Inherited() { } + + explicit + tuple(typename __add_c_ref<_T1>::type __a1, + typename __add_c_ref<_T2>::type __a2) + : _Inherited(__a1, __a2) { } + + template + tuple(const tuple<_U1, _U2>& __in) + : _Inherited(__in) { } + + tuple(const tuple& __in) + : _Inherited(__in) { } + + template + tuple(const pair<_U1, _U2>& __in) + : _Inherited( + _Tuple_impl<0, + typename __add_c_ref<_U1>::type, + typename __add_c_ref<_U2>::type>(__in.first, + __in.second)) + { + } + + template + tuple& operator=(const tuple<_U1, _U2>& __in) + { + static_cast<_Inherited&>(*this) = __in; + return *this; + } + + tuple& operator=(const tuple& __in) + { + static_cast<_Inherited&>(*this) = __in; + return *this; + } + + template + tuple& operator=(const pair<_U1, _U2>& __in) + { + this->_M_head = __in.first; + this->_M_tail()._M_head = __in.second; + return *this; + } }; + + /// Gives the type of the ith element of a given tuple type. + template + struct tuple_element; + + /** + * @if maint + * Recursive case for tuple_element: strip off the first element in + * the tuple and retrieve the (i-1)th element of the remaining tuple. + * @endif + */ + template + struct tuple_element<__i, tuple<_Head, _Tail...> > + : tuple_element<__i - 1, tuple<_Tail...> > { }; + + /** + * @if maint + * Basis case for tuple_element: The first element is the one we're seeking. + * @endif + */ + template + struct tuple_element<0, tuple<_Head, _Tail...> > + { + typedef _Head type; + }; + + /// Finds the size of a given tuple type. template - struct __strip_reference_wrapper > + struct tuple_size; + + /// @brief class tuple_size + template + struct tuple_size > { - typedef _Tp& __type; + static const int value = sizeof...(_Elements); }; - #include "tuple_defs.h" + // 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 + inline typename __add_ref<_Head>::type + get(_Tuple_impl<__i, _Head, _Tail...>& __t) + { + return __t._M_head; + } + + template + inline typename __add_c_ref<_Head>::type + get(const _Tuple_impl<__i, _Head, _Tail...>& __t) + { + return __t._M_head; + } + + // This class helps construct the various comparison operations on tuples + template + struct __tuple_compare; template struct __tuple_compare<0, __i, __j, _Tp, _Up> @@ -129,6 +304,80 @@ _GLIBCXX_BEGIN_NAMESPACE(_GLIBCXX_TR1) { return false; } }; + template + bool + operator==(const tuple<_TElements...>& __t, const tuple<_UElements...>& __u) + { + typedef tuple<_TElements...> _Tp; + typedef tuple<_UElements...> _Up; + return __tuple_compare::value - tuple_size<_Tp>::value, 0, + tuple_size<_Tp>::value, _Tp, _Up>::__eq(__t, __u); + } + + template + bool + operator<(const tuple<_TElements...>& __t, const tuple<_UElements...>& __u) + { + typedef tuple<_TElements...> _Tp; + typedef tuple<_UElements...> _Up; + return __tuple_compare::value - tuple_size<_Tp>::value, 0, + tuple_size<_Tp>::value, _Tp, _Up>::__less(__t, __u); + } + + template + bool + operator!=(const tuple<_TElements...>& __t, const tuple<_UElements...>& __u) + { return !(__t == __u); } + + template + bool + operator>(const tuple<_TElements...>& __t, const tuple<_UElements...>& __u) + { return __u < __t; } + + template + bool + operator<=(const tuple<_TElements...>& __t, const tuple<_UElements...>& __u) + { return !(__u < __t); } + + template + bool + operator>=(const tuple<_TElements...>& __t, const tuple<_UElements...>& __u) + { return !(__t < __u); } + + // Helper which adds a reference to a type when given a reference_wrapper + template + struct __strip_reference_wrapper + { + typedef _Tp __type; + }; + + template + struct __strip_reference_wrapper > + { + typedef _Tp& __type; + }; + + template + struct __strip_reference_wrapper > + { + typedef _Tp& __type; + }; + + template + inline tuple::__type...> + make_tuple(_Elements... __args) + { + typedef tuple::__type...> + __result_type; + return __result_type(__args...); + } + + template + inline tuple<_Elements&...> tie(_Elements&... __args) + { + return tuple<_Elements&...>(__args...); + } + // A class (and instance) which can be used in 'tie' when an element // of a tuple is not required struct swallow_assign @@ -148,14 +397,6 @@ _GLIBCXX_BEGIN_NAMESPACE(_GLIBCXX_TR1) _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 -#include -#undef _GLIBCXX_REPEAT_HEADER -#undef _SHORT_REPEAT - #include #endif diff --git a/libstdc++-v3/include/tr1/tuple_iterate.h b/libstdc++-v3/include/tr1/tuple_iterate.h deleted file mode 100644 index 4a9e494..0000000 --- a/libstdc++-v3/include/tr1/tuple_iterate.h +++ /dev/null @@ -1,172 +0,0 @@ -// 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 - -namespace std -{ -_GLIBCXX_BEGIN_NAMESPACE(_GLIBCXX_TR1) - -/// @brief class tuple_size -template<_GLIBCXX_TEMPLATE_PARAMS> - struct tuple_size > - { static const int value = _GLIBCXX_NUM_ARGS; }; - -#if _GLIBCXX_NUM_ARGS > 0 -template<_GLIBCXX_TEMPLATE_PARAMS> - const int tuple_size >::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 - tuple(const std::pair<_U1, _U2>& __u) : - _M_arg1(__u.first), _M_arg2(__u.second) - { } - - template - 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 - friend class __get_helper; - - template<_GLIBCXX_TUPLE_ALL_TEMPLATE_PARAMS_UNNAMED> - friend class tuple; - }; - -#ifndef _GLIBCXX_LAST_INCLUDE - -template - struct __get_helper<_GLIBCXX_NUM_ARGS, _Tp> - { - static typename __add_ref::type>::type - get_value(_Tp& __in) - { return __in._GLIBCXX_CAT(_M_arg,_GLIBCXX_NUM_ARGS_PLUS_1); } - - static typename __add_c_ref::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 -}