gcc/libstdc++-v3/include/ext/type_traits.h

244 lines
6.5 KiB
C
Raw Normal View History

type_traits.h: New. 2006-09-18 Benjamin Kosnik <bkoz@redhat.com> Peter Doerfler <gcc@pdoerfler.com> Paolo Carlini <pcarlini@suse.de> * include/ext/type_traits.h: New. (__conditional_type): New. (__numeric_traits): New. (__add_unsigned): New. (__remove_unsigned): New. (__enable_if): New. * include/Makefile.am: Add. * include/Makefile.in: Regenerate. * include/ext/pb_ds/detail/type_utils.hpp: Use ext include, remove duplicates. * include/tr1/hashtable_policy.h (IF): Use __conditional_type. (_Max_digits10): Same. (identity): Use _Identity. (extract1st): Use _Select1st. * include/tr1/random (_Select): Use __conditional_type. (_To_Unsigned_Type): Use __add_unsigned. Linebreak fixups. * include/bits/locale_facets.tcc (__to_unsigned_type): Remove, use __add_unsigned. * include/tr1/random.tcc: Fixups as above. * include/tr1/unordered_map: Same. * include/tr1/hashtable: Same. * include/tr1/unordered_set: Same. * include/ext/pb_ds/detail/gp_hash_table_map_/ standard_policies.hpp: Same. * include/ext/pb_ds/detail/standard_policies.hpp: Same. * include/ext/pb_ds/detail/typelist/typelist_filter.hpp: Same. * include/ext/pb_ds/detail/binary_heap_/binary_heap_.hpp: Same. * include/ext/pb_ds/detail/type_utils.hpp: Same. * include/ext/pb_ds/trie_policy.hpp: Same. * docs/html/ext/pb_ds/string_trie_e_access_traits.html: Same. * include/bits/cpp_type_traits.h (__enable_if): Move to ext, make boolean argument first. * include/bits/locale_facets.h: Fixups for __enable_if argument and namespace switch. * include/bits/stl_algobase.h: Same. * include/bits/stl_algo.h: Same. * include/bits/stl_iterator.h: Same. * include/bits/streambuf_iterator.h: Same. * include/debug/safe_iterator.h: Same. * include/tr1/hashtable_policy.h: Same. * include/tr1/cmath: Same. * include/tr1/functional: Same. * include/tr1/functional_iterate.h: Same. * include/std/std_streambuf.h: Same. * include/c_std/std_cmath.h: Same. * testsuite/util/testsuite_tr1.h: Same. * testsuite/util/performance/assoc/multimap_common_type.hpp: Same. Co-Authored-By: Paolo Carlini <pcarlini@suse.de> Co-Authored-By: Peter Doerfler <gcc@pdoerfler.com> From-SVN: r117024
2006-09-18 15:30:56 +02:00
// -*- C++ -*-
2022-01-03 10:42:10 +01:00
// Copyright (C) 2005-2022 Free Software Foundation, Inc.
type_traits.h: New. 2006-09-18 Benjamin Kosnik <bkoz@redhat.com> Peter Doerfler <gcc@pdoerfler.com> Paolo Carlini <pcarlini@suse.de> * include/ext/type_traits.h: New. (__conditional_type): New. (__numeric_traits): New. (__add_unsigned): New. (__remove_unsigned): New. (__enable_if): New. * include/Makefile.am: Add. * include/Makefile.in: Regenerate. * include/ext/pb_ds/detail/type_utils.hpp: Use ext include, remove duplicates. * include/tr1/hashtable_policy.h (IF): Use __conditional_type. (_Max_digits10): Same. (identity): Use _Identity. (extract1st): Use _Select1st. * include/tr1/random (_Select): Use __conditional_type. (_To_Unsigned_Type): Use __add_unsigned. Linebreak fixups. * include/bits/locale_facets.tcc (__to_unsigned_type): Remove, use __add_unsigned. * include/tr1/random.tcc: Fixups as above. * include/tr1/unordered_map: Same. * include/tr1/hashtable: Same. * include/tr1/unordered_set: Same. * include/ext/pb_ds/detail/gp_hash_table_map_/ standard_policies.hpp: Same. * include/ext/pb_ds/detail/standard_policies.hpp: Same. * include/ext/pb_ds/detail/typelist/typelist_filter.hpp: Same. * include/ext/pb_ds/detail/binary_heap_/binary_heap_.hpp: Same. * include/ext/pb_ds/detail/type_utils.hpp: Same. * include/ext/pb_ds/trie_policy.hpp: Same. * docs/html/ext/pb_ds/string_trie_e_access_traits.html: Same. * include/bits/cpp_type_traits.h (__enable_if): Move to ext, make boolean argument first. * include/bits/locale_facets.h: Fixups for __enable_if argument and namespace switch. * include/bits/stl_algobase.h: Same. * include/bits/stl_algo.h: Same. * include/bits/stl_iterator.h: Same. * include/bits/streambuf_iterator.h: Same. * include/debug/safe_iterator.h: Same. * include/tr1/hashtable_policy.h: Same. * include/tr1/cmath: Same. * include/tr1/functional: Same. * include/tr1/functional_iterate.h: Same. * include/std/std_streambuf.h: Same. * include/c_std/std_cmath.h: Same. * testsuite/util/testsuite_tr1.h: Same. * testsuite/util/performance/assoc/multimap_common_type.hpp: Same. Co-Authored-By: Paolo Carlini <pcarlini@suse.de> Co-Authored-By: Peter Doerfler <gcc@pdoerfler.com> From-SVN: r117024
2006-09-18 15:30:56 +02:00
//
// 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 3, or (at your option) any later
type_traits.h: New. 2006-09-18 Benjamin Kosnik <bkoz@redhat.com> Peter Doerfler <gcc@pdoerfler.com> Paolo Carlini <pcarlini@suse.de> * include/ext/type_traits.h: New. (__conditional_type): New. (__numeric_traits): New. (__add_unsigned): New. (__remove_unsigned): New. (__enable_if): New. * include/Makefile.am: Add. * include/Makefile.in: Regenerate. * include/ext/pb_ds/detail/type_utils.hpp: Use ext include, remove duplicates. * include/tr1/hashtable_policy.h (IF): Use __conditional_type. (_Max_digits10): Same. (identity): Use _Identity. (extract1st): Use _Select1st. * include/tr1/random (_Select): Use __conditional_type. (_To_Unsigned_Type): Use __add_unsigned. Linebreak fixups. * include/bits/locale_facets.tcc (__to_unsigned_type): Remove, use __add_unsigned. * include/tr1/random.tcc: Fixups as above. * include/tr1/unordered_map: Same. * include/tr1/hashtable: Same. * include/tr1/unordered_set: Same. * include/ext/pb_ds/detail/gp_hash_table_map_/ standard_policies.hpp: Same. * include/ext/pb_ds/detail/standard_policies.hpp: Same. * include/ext/pb_ds/detail/typelist/typelist_filter.hpp: Same. * include/ext/pb_ds/detail/binary_heap_/binary_heap_.hpp: Same. * include/ext/pb_ds/detail/type_utils.hpp: Same. * include/ext/pb_ds/trie_policy.hpp: Same. * docs/html/ext/pb_ds/string_trie_e_access_traits.html: Same. * include/bits/cpp_type_traits.h (__enable_if): Move to ext, make boolean argument first. * include/bits/locale_facets.h: Fixups for __enable_if argument and namespace switch. * include/bits/stl_algobase.h: Same. * include/bits/stl_algo.h: Same. * include/bits/stl_iterator.h: Same. * include/bits/streambuf_iterator.h: Same. * include/debug/safe_iterator.h: Same. * include/tr1/hashtable_policy.h: Same. * include/tr1/cmath: Same. * include/tr1/functional: Same. * include/tr1/functional_iterate.h: Same. * include/std/std_streambuf.h: Same. * include/c_std/std_cmath.h: Same. * testsuite/util/testsuite_tr1.h: Same. * testsuite/util/performance/assoc/multimap_common_type.hpp: Same. Co-Authored-By: Paolo Carlini <pcarlini@suse.de> Co-Authored-By: Peter Doerfler <gcc@pdoerfler.com> From-SVN: r117024
2006-09-18 15:30:56 +02:00
// 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.
// Under Section 7 of GPL version 3, you are granted additional
// permissions described in the GCC Runtime Library Exception, version
// 3.1, as published by the Free Software Foundation.
// You should have received a copy of the GNU General Public License and
// a copy of the GCC Runtime Library Exception along with this program;
// see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
// <http://www.gnu.org/licenses/>.
type_traits.h: New. 2006-09-18 Benjamin Kosnik <bkoz@redhat.com> Peter Doerfler <gcc@pdoerfler.com> Paolo Carlini <pcarlini@suse.de> * include/ext/type_traits.h: New. (__conditional_type): New. (__numeric_traits): New. (__add_unsigned): New. (__remove_unsigned): New. (__enable_if): New. * include/Makefile.am: Add. * include/Makefile.in: Regenerate. * include/ext/pb_ds/detail/type_utils.hpp: Use ext include, remove duplicates. * include/tr1/hashtable_policy.h (IF): Use __conditional_type. (_Max_digits10): Same. (identity): Use _Identity. (extract1st): Use _Select1st. * include/tr1/random (_Select): Use __conditional_type. (_To_Unsigned_Type): Use __add_unsigned. Linebreak fixups. * include/bits/locale_facets.tcc (__to_unsigned_type): Remove, use __add_unsigned. * include/tr1/random.tcc: Fixups as above. * include/tr1/unordered_map: Same. * include/tr1/hashtable: Same. * include/tr1/unordered_set: Same. * include/ext/pb_ds/detail/gp_hash_table_map_/ standard_policies.hpp: Same. * include/ext/pb_ds/detail/standard_policies.hpp: Same. * include/ext/pb_ds/detail/typelist/typelist_filter.hpp: Same. * include/ext/pb_ds/detail/binary_heap_/binary_heap_.hpp: Same. * include/ext/pb_ds/detail/type_utils.hpp: Same. * include/ext/pb_ds/trie_policy.hpp: Same. * docs/html/ext/pb_ds/string_trie_e_access_traits.html: Same. * include/bits/cpp_type_traits.h (__enable_if): Move to ext, make boolean argument first. * include/bits/locale_facets.h: Fixups for __enable_if argument and namespace switch. * include/bits/stl_algobase.h: Same. * include/bits/stl_algo.h: Same. * include/bits/stl_iterator.h: Same. * include/bits/streambuf_iterator.h: Same. * include/debug/safe_iterator.h: Same. * include/tr1/hashtable_policy.h: Same. * include/tr1/cmath: Same. * include/tr1/functional: Same. * include/tr1/functional_iterate.h: Same. * include/std/std_streambuf.h: Same. * include/c_std/std_cmath.h: Same. * testsuite/util/testsuite_tr1.h: Same. * testsuite/util/performance/assoc/multimap_common_type.hpp: Same. Co-Authored-By: Paolo Carlini <pcarlini@suse.de> Co-Authored-By: Peter Doerfler <gcc@pdoerfler.com> From-SVN: r117024
2006-09-18 15:30:56 +02:00
throw_allocator.h: Consistent @file markup. 2006-11-29 Benjamin Kosnik <bkoz@redhat.com> * include/ext/throw_allocator.h: Consistent @file markup. * include/ext/type_traits.h: Same. * include/debug/hash_map: Same. * include/debug/hash_multimap.h: Same. * include/debug/set.h: Same. * include/debug/hash_set.h: Same. * include/debug/formatter.h: Same. * include/debug/bitset: Same. * include/debug/set: Same. * include/debug/multiset.h: Same. * include/debug/safe_sequence.h: Same. * include/debug/hash_set: Same. * include/debug/functions.h: Same. * include/debug/safe_base.h: Same. * include/debug/hash_multiset.h: Same. * include/debug/safe_iterator.tcc: Same. * include/debug/vector: Same. * include/debug/map.h: Same. * include/debug/deque: Same. * include/debug/hash_map.h: Same. * include/debug/string: Same. * include/debug/macros.h: Same. * include/debug/list: Same. * include/debug/debug.h: Same. * include/debug/map: Same. * include/debug/safe_iterator.h: Same. * include/debug/multimap.h: Same. * config/cpu/generic/atomicity_mutex/atomicity.h: Same. * config/cpu/generic/atomicity_builtins/atomicity.h: Same. * config/cpu/generic/atomic_word.h: Same. * include/tr1/memory: Same. * include/tr1/random: Same. * include/std/std_queue.h: Same. * include/std/std_iterator.h: Same. * include/std/std_bitset.h: Same. * include/std/std_set.h: Same. * include/std/std_vector.h: Same. * include/std/std_deque.h: Same. * include/std/std_utility.h: Same. * include/std/std_stack.h: Same. * include/std/std_string.h: Same. * include/std/std_list.h: Same. * include/std/std_map.h: Same. * libsupc++/typeinfo: Same. * libsupc++/exception: Same. * libsupc++/exception_defines.h: Same. * libsupc++/new: Same. * include/ext/bitmap_allocator.h: Change namespace __balloc to __detail. * src/bitmap_allocator.cc: Same. * include/bits/cpp_type_traits.h: Change __true_type and __false_type from global to namespace std scope. * include/ext/slist: Same. * include/ext/vstring.h: Same. * include/ext/vstring.tcc: Same. * include/ext/rc_string_base.h: Same. * include/ext/sso_string_base.h: Same. * include/bits/codecvt.h: Adjust markup so that correct namespace scope information is in all files. * include/bits/locale_facets.h: Same. Include ctype_base directly. * config/os/windiss/ctype_base.h: Add in namespace markup. * config/os/newlib/ctype_base.h: Same. * config/os/aix/ctype_base.h: Same. * config/os/vxworks/ctype_base.h: Same. * config/os/hpux/ctype_base.h: Same. * config/os/mingw32/ctype_base.h: Same. * config/os/gnu-linux/ctype_base.h: Same. * config/os/tpf/ctype_base.h: Same. * config/os/uclibc/ctype_base.h: Same. * config/os/djgpp/ctype_base.h: Same. * config/os/qnx/qnx6.1/ctype_base.h: Same. * config/os/bsd/netbsd/ctype_base.h: Same. * config/os/bsd/darwin/ctype_base.h: Same. * config/os/bsd/freebsd/ctype_base.h: Same. * config/os/irix/irix5.2/ctype_base.h: Same. * config/os/irix/irix6.5/ctype_base.h: Same. * config/os/solaris/solaris2.5/ctype_base.h: Same. * config/os/solaris/solaris2.6/ctype_base.h: Same. * config/os/solaris/solaris2.7/ctype_base.h: Same. * config/os/generic/ctype_base.h: Same. * include/tr1/mu_iterate.h: Same. * include/tr1/tuple: Same. * include/tr1/tuple_iterate.h: Same. * include/tr1/tuple_defs.h: Same. * include/tr1/random.tcc: Same. * include/tr1/functional: Same. * include/tr1/functional_iterate.h: Same. * testsuite/ext/type_traits/remove_unsigned_integer_neg.cc: Line number changes. * testsuite/ext/type_traits/add_unsigned_floating_neg.cc: Same. * testsuite/ext/type_traits/remove_unsigned_floating_neg.cc: Same. * testsuite/ext/type_traits/add_unsigned_integer_neg.cc: Same. * docs/doxygen/user.cfg.in: Update to doxygen 1.5.1. * docs/html/17_intro/license.html: Updated info for generated docs. * docs/doxygen/guide.html: Adjust. * docs/doxygen/run_doxygen: Adjust. * docs/doxygen/mainpage.html: Same. * docs/doxygen/doxygroups.cc: Same. * docs/doxygen/Intro.3: Same. * docs/doxygen/tables.html: Same. From-SVN: r119334
2006-11-29 21:59:22 +01:00
/** @file ext/type_traits.h
* This file is a GNU extension to the Standard C++ Library.
*/
type_traits.h: New. 2006-09-18 Benjamin Kosnik <bkoz@redhat.com> Peter Doerfler <gcc@pdoerfler.com> Paolo Carlini <pcarlini@suse.de> * include/ext/type_traits.h: New. (__conditional_type): New. (__numeric_traits): New. (__add_unsigned): New. (__remove_unsigned): New. (__enable_if): New. * include/Makefile.am: Add. * include/Makefile.in: Regenerate. * include/ext/pb_ds/detail/type_utils.hpp: Use ext include, remove duplicates. * include/tr1/hashtable_policy.h (IF): Use __conditional_type. (_Max_digits10): Same. (identity): Use _Identity. (extract1st): Use _Select1st. * include/tr1/random (_Select): Use __conditional_type. (_To_Unsigned_Type): Use __add_unsigned. Linebreak fixups. * include/bits/locale_facets.tcc (__to_unsigned_type): Remove, use __add_unsigned. * include/tr1/random.tcc: Fixups as above. * include/tr1/unordered_map: Same. * include/tr1/hashtable: Same. * include/tr1/unordered_set: Same. * include/ext/pb_ds/detail/gp_hash_table_map_/ standard_policies.hpp: Same. * include/ext/pb_ds/detail/standard_policies.hpp: Same. * include/ext/pb_ds/detail/typelist/typelist_filter.hpp: Same. * include/ext/pb_ds/detail/binary_heap_/binary_heap_.hpp: Same. * include/ext/pb_ds/detail/type_utils.hpp: Same. * include/ext/pb_ds/trie_policy.hpp: Same. * docs/html/ext/pb_ds/string_trie_e_access_traits.html: Same. * include/bits/cpp_type_traits.h (__enable_if): Move to ext, make boolean argument first. * include/bits/locale_facets.h: Fixups for __enable_if argument and namespace switch. * include/bits/stl_algobase.h: Same. * include/bits/stl_algo.h: Same. * include/bits/stl_iterator.h: Same. * include/bits/streambuf_iterator.h: Same. * include/debug/safe_iterator.h: Same. * include/tr1/hashtable_policy.h: Same. * include/tr1/cmath: Same. * include/tr1/functional: Same. * include/tr1/functional_iterate.h: Same. * include/std/std_streambuf.h: Same. * include/c_std/std_cmath.h: Same. * testsuite/util/testsuite_tr1.h: Same. * testsuite/util/performance/assoc/multimap_common_type.hpp: Same. Co-Authored-By: Paolo Carlini <pcarlini@suse.de> Co-Authored-By: Peter Doerfler <gcc@pdoerfler.com> From-SVN: r117024
2006-09-18 15:30:56 +02:00
#ifndef _EXT_TYPE_TRAITS
#define _EXT_TYPE_TRAITS 1
#pragma GCC system_header
#include <bits/c++config.h>
#include <bits/cpp_type_traits.h>
type_traits.h: New. 2006-09-18 Benjamin Kosnik <bkoz@redhat.com> Peter Doerfler <gcc@pdoerfler.com> Paolo Carlini <pcarlini@suse.de> * include/ext/type_traits.h: New. (__conditional_type): New. (__numeric_traits): New. (__add_unsigned): New. (__remove_unsigned): New. (__enable_if): New. * include/Makefile.am: Add. * include/Makefile.in: Regenerate. * include/ext/pb_ds/detail/type_utils.hpp: Use ext include, remove duplicates. * include/tr1/hashtable_policy.h (IF): Use __conditional_type. (_Max_digits10): Same. (identity): Use _Identity. (extract1st): Use _Select1st. * include/tr1/random (_Select): Use __conditional_type. (_To_Unsigned_Type): Use __add_unsigned. Linebreak fixups. * include/bits/locale_facets.tcc (__to_unsigned_type): Remove, use __add_unsigned. * include/tr1/random.tcc: Fixups as above. * include/tr1/unordered_map: Same. * include/tr1/hashtable: Same. * include/tr1/unordered_set: Same. * include/ext/pb_ds/detail/gp_hash_table_map_/ standard_policies.hpp: Same. * include/ext/pb_ds/detail/standard_policies.hpp: Same. * include/ext/pb_ds/detail/typelist/typelist_filter.hpp: Same. * include/ext/pb_ds/detail/binary_heap_/binary_heap_.hpp: Same. * include/ext/pb_ds/detail/type_utils.hpp: Same. * include/ext/pb_ds/trie_policy.hpp: Same. * docs/html/ext/pb_ds/string_trie_e_access_traits.html: Same. * include/bits/cpp_type_traits.h (__enable_if): Move to ext, make boolean argument first. * include/bits/locale_facets.h: Fixups for __enable_if argument and namespace switch. * include/bits/stl_algobase.h: Same. * include/bits/stl_algo.h: Same. * include/bits/stl_iterator.h: Same. * include/bits/streambuf_iterator.h: Same. * include/debug/safe_iterator.h: Same. * include/tr1/hashtable_policy.h: Same. * include/tr1/cmath: Same. * include/tr1/functional: Same. * include/tr1/functional_iterate.h: Same. * include/std/std_streambuf.h: Same. * include/c_std/std_cmath.h: Same. * testsuite/util/testsuite_tr1.h: Same. * testsuite/util/performance/assoc/multimap_common_type.hpp: Same. Co-Authored-By: Paolo Carlini <pcarlini@suse.de> Co-Authored-By: Peter Doerfler <gcc@pdoerfler.com> From-SVN: r117024
2006-09-18 15:30:56 +02:00
extern "C++" {
PR libstdc++/36104 part four 2011-01-30 Benjamin Kosnik <bkoz@redhat.com> PR libstdc++/36104 part four * include/bits/c++config (_GLIBCXX_STD): Remove. (_GLIBCXX_STD_D, _GLIBCXX_PR): Now _GLIBCXX_STD_C. (_GLIBCXX_P): Now _GLIBCXX_STD_A. (_GLIBCXX_NAMESPACE_DEBUG, _GLIBCXX_NAMESPACE_PARALLEL, _GLIBCXX_NAMESPACE_PROFILE, _GLIBCXX_NAMESPACE_VERSION): Remove. (_GLIBCXX_INLINE_DEBUG, _GLIBCXX_INLINE_PARALLEL, _GLIBCXX_INLINE_PROFILE): Remove. (_GLIBCXX_BEGIN_NAMESPACE(X)): Remove. (_GLIBCXX_END_NAMESPACE): Remove. (_GLIBCXX_BEGIN_NESTED_NAMESPACE(X, Y)): Remove. (_GLIBCXX_END_NESTED_NAMESPACE): Remove. (_GLIBCXX_BEGIN_NAMESPACE_ALGO): Add. (_GLIBCXX_END_NAMESPACE_ALGO): Add. (_GLIBCXX_BEGIN_NAMESPACE_CONTAINER): Add. (_GLIBCXX_END_NAMESPACE_CONTAINER): Add. (_GLIBCXX_BEGIN_NAMESPACE_VERSION): Add. (_GLIBCXX_END_NAMESPACE_VERSION): Add. (_GLIBCXX_BEGIN_LDBL_NAMESPACE): To _GLIBCXX_BEGIN_NAMESPACE_LDBL. (_GLIBCXX_END_LDBL_NAMESPACE): To _GLIBCXX_END_NAMESPACE_LDBL. (_GLIBCXX_VISIBILITY_ATTR): Revert to _GLIBCXX_VISIBILITY. * include/*: Use new macros for namespace scope. * config/*: Same. * src/*: Same. * src/Makefile.am (sources): Remove debug_list.cc, add compatibility-debug_list-2.cc. (parallel_sources): Remove parallel_list.cc, add compatibility-parallel_list-2.cc. (compatibility-parallel_list-2.[o,lo]): New rule. * src/Makefile.in: Regenerate. * src/debug_list.cc: Remove. * src/parallel_list.cc: Remove. * src/compatibility-list-2.cc: New. * src/compatibility-debug_list-2.cc: New. * src/compatibility-parallel_list-2.cc: New. * doc/doxygen/user.cfg.in: Adjust macros. * testsuite/20_util/auto_ptr/assign_neg.cc: Adjust line numbers, macros. * testsuite/20_util/declval/requirements/1_neg.cc: Same. * testsuite/20_util/duration/requirements/typedefs_neg1.cc: Same. * testsuite/20_util/duration/requirements/typedefs_neg2.cc: Same. * testsuite/20_util/duration/requirements/typedefs_neg3.cc: Same. * testsuite/20_util/forward/c_neg.cc: Same. * testsuite/20_util/forward/f_neg.cc: Same. * testsuite/20_util/make_signed/requirements/typedefs_neg.cc: Same. * testsuite/20_util/make_unsigned/requirements/typedefs_neg.cc: Same. * testsuite/20_util/ratio/cons/cons_overflow_neg.cc: Same. * testsuite/20_util/ratio/operations/ops_overflow_neg.cc: Same. * testsuite/20_util/shared_ptr/cons/43820_neg.cc: Same. * testsuite/20_util/weak_ptr/comparison/cmp_neg.cc: Same. * testsuite/23_containers/deque/requirements/dr438/assign_neg.cc: Same. * testsuite/23_containers/deque/requirements/dr438/ constructor_1_neg.cc: Same. * testsuite/23_containers/deque/requirements/dr438/ constructor_2_neg.cc: Same. * testsuite/23_containers/deque/requirements/dr438/insert_neg.cc: Same. * testsuite/23_containers/forward_list/capacity/1.cc: Same. * testsuite/23_containers/forward_list/requirements/dr438/ assign_neg.cc: Same. * testsuite/23_containers/forward_list/requirements/dr438/ constructor_1_neg.cc: Same. * testsuite/23_containers/forward_list/requirements/dr438/ constructor_2_neg.cc: Same. * testsuite/23_containers/forward_list/requirements/dr438/ insert_neg.cc: Same. * testsuite/23_containers/list/capacity/29134.cc: Same. * testsuite/23_containers/list/requirements/dr438/assign_neg.cc: Same. * testsuite/23_containers/list/requirements/dr438/ constructor_1_neg.cc: Same. * testsuite/23_containers/list/requirements/dr438/ constructor_2_neg.cc: Same. * testsuite/23_containers/list/requirements/dr438/insert_neg.cc: Same. * testsuite/23_containers/vector/bool/capacity/29134.cc: Same. * testsuite/23_containers/vector/bool/modifiers/insert/31370.cc: Same. * testsuite/23_containers/vector/requirements/dr438/assign_neg.cc: Same. * testsuite/23_containers/vector/requirements/dr438/ constructor_1_neg.cc: Same. * testsuite/23_containers/vector/requirements/dr438/ constructor_2_neg.cc: Same. * testsuite/23_containers/vector/requirements/dr438/insert_neg.cc: Same. * testsuite/25_algorithms/sort/35588.cc: Same. * testsuite/27_io/ios_base/cons/assign_neg.cc: Same. * testsuite/27_io/ios_base/cons/copy_neg.cc: Same. * testsuite/ext/profile/mutex_extensions_neg.cc: Same. * testsuite/ext/profile/profiler_algos.cc: Same. * testsuite/ext/type_traits/add_unsigned_floating_neg.cc: Same. * testsuite/ext/type_traits/add_unsigned_integer_neg.cc: Same. * testsuite/ext/type_traits/remove_unsigned_floating_neg.cc: Same. * testsuite/ext/type_traits/remove_unsigned_integer_neg.cc: Same. * testsuite/tr1/2_general_utilities/shared_ptr/cons/43820_neg.cc: Same. From-SVN: r169421
2011-01-30 23:39:36 +01:00
namespace __gnu_cxx _GLIBCXX_VISIBILITY(default)
{
_GLIBCXX_BEGIN_NAMESPACE_VERSION
type_traits.h: New. 2006-09-18 Benjamin Kosnik <bkoz@redhat.com> Peter Doerfler <gcc@pdoerfler.com> Paolo Carlini <pcarlini@suse.de> * include/ext/type_traits.h: New. (__conditional_type): New. (__numeric_traits): New. (__add_unsigned): New. (__remove_unsigned): New. (__enable_if): New. * include/Makefile.am: Add. * include/Makefile.in: Regenerate. * include/ext/pb_ds/detail/type_utils.hpp: Use ext include, remove duplicates. * include/tr1/hashtable_policy.h (IF): Use __conditional_type. (_Max_digits10): Same. (identity): Use _Identity. (extract1st): Use _Select1st. * include/tr1/random (_Select): Use __conditional_type. (_To_Unsigned_Type): Use __add_unsigned. Linebreak fixups. * include/bits/locale_facets.tcc (__to_unsigned_type): Remove, use __add_unsigned. * include/tr1/random.tcc: Fixups as above. * include/tr1/unordered_map: Same. * include/tr1/hashtable: Same. * include/tr1/unordered_set: Same. * include/ext/pb_ds/detail/gp_hash_table_map_/ standard_policies.hpp: Same. * include/ext/pb_ds/detail/standard_policies.hpp: Same. * include/ext/pb_ds/detail/typelist/typelist_filter.hpp: Same. * include/ext/pb_ds/detail/binary_heap_/binary_heap_.hpp: Same. * include/ext/pb_ds/detail/type_utils.hpp: Same. * include/ext/pb_ds/trie_policy.hpp: Same. * docs/html/ext/pb_ds/string_trie_e_access_traits.html: Same. * include/bits/cpp_type_traits.h (__enable_if): Move to ext, make boolean argument first. * include/bits/locale_facets.h: Fixups for __enable_if argument and namespace switch. * include/bits/stl_algobase.h: Same. * include/bits/stl_algo.h: Same. * include/bits/stl_iterator.h: Same. * include/bits/streambuf_iterator.h: Same. * include/debug/safe_iterator.h: Same. * include/tr1/hashtable_policy.h: Same. * include/tr1/cmath: Same. * include/tr1/functional: Same. * include/tr1/functional_iterate.h: Same. * include/std/std_streambuf.h: Same. * include/c_std/std_cmath.h: Same. * testsuite/util/testsuite_tr1.h: Same. * testsuite/util/performance/assoc/multimap_common_type.hpp: Same. Co-Authored-By: Paolo Carlini <pcarlini@suse.de> Co-Authored-By: Peter Doerfler <gcc@pdoerfler.com> From-SVN: r117024
2006-09-18 15:30:56 +02:00
// Define a nested type if some predicate holds.
template<bool, typename>
struct __enable_if
{ };
template<typename _Tp>
struct __enable_if<true, _Tp>
{ typedef _Tp __type; };
type_traits.h: New. 2006-09-18 Benjamin Kosnik <bkoz@redhat.com> Peter Doerfler <gcc@pdoerfler.com> Paolo Carlini <pcarlini@suse.de> * include/ext/type_traits.h: New. (__conditional_type): New. (__numeric_traits): New. (__add_unsigned): New. (__remove_unsigned): New. (__enable_if): New. * include/Makefile.am: Add. * include/Makefile.in: Regenerate. * include/ext/pb_ds/detail/type_utils.hpp: Use ext include, remove duplicates. * include/tr1/hashtable_policy.h (IF): Use __conditional_type. (_Max_digits10): Same. (identity): Use _Identity. (extract1st): Use _Select1st. * include/tr1/random (_Select): Use __conditional_type. (_To_Unsigned_Type): Use __add_unsigned. Linebreak fixups. * include/bits/locale_facets.tcc (__to_unsigned_type): Remove, use __add_unsigned. * include/tr1/random.tcc: Fixups as above. * include/tr1/unordered_map: Same. * include/tr1/hashtable: Same. * include/tr1/unordered_set: Same. * include/ext/pb_ds/detail/gp_hash_table_map_/ standard_policies.hpp: Same. * include/ext/pb_ds/detail/standard_policies.hpp: Same. * include/ext/pb_ds/detail/typelist/typelist_filter.hpp: Same. * include/ext/pb_ds/detail/binary_heap_/binary_heap_.hpp: Same. * include/ext/pb_ds/detail/type_utils.hpp: Same. * include/ext/pb_ds/trie_policy.hpp: Same. * docs/html/ext/pb_ds/string_trie_e_access_traits.html: Same. * include/bits/cpp_type_traits.h (__enable_if): Move to ext, make boolean argument first. * include/bits/locale_facets.h: Fixups for __enable_if argument and namespace switch. * include/bits/stl_algobase.h: Same. * include/bits/stl_algo.h: Same. * include/bits/stl_iterator.h: Same. * include/bits/streambuf_iterator.h: Same. * include/debug/safe_iterator.h: Same. * include/tr1/hashtable_policy.h: Same. * include/tr1/cmath: Same. * include/tr1/functional: Same. * include/tr1/functional_iterate.h: Same. * include/std/std_streambuf.h: Same. * include/c_std/std_cmath.h: Same. * testsuite/util/testsuite_tr1.h: Same. * testsuite/util/performance/assoc/multimap_common_type.hpp: Same. Co-Authored-By: Paolo Carlini <pcarlini@suse.de> Co-Authored-By: Peter Doerfler <gcc@pdoerfler.com> From-SVN: r117024
2006-09-18 15:30:56 +02:00
// Conditional expression for types. If true, first, if false, second.
template<bool _Cond, typename _Iftrue, typename _Iffalse>
struct __conditional_type
{ typedef _Iftrue __type; };
template<typename _Iftrue, typename _Iffalse>
struct __conditional_type<false, _Iftrue, _Iffalse>
{ typedef _Iffalse __type; };
// Given an integral builtin type, return the corresponding unsigned type.
template<typename _Tp>
type_traits.h: New. 2006-09-18 Benjamin Kosnik <bkoz@redhat.com> Peter Doerfler <gcc@pdoerfler.com> Paolo Carlini <pcarlini@suse.de> * include/ext/type_traits.h: New. (__conditional_type): New. (__numeric_traits): New. (__add_unsigned): New. (__remove_unsigned): New. (__enable_if): New. * include/Makefile.am: Add. * include/Makefile.in: Regenerate. * include/ext/pb_ds/detail/type_utils.hpp: Use ext include, remove duplicates. * include/tr1/hashtable_policy.h (IF): Use __conditional_type. (_Max_digits10): Same. (identity): Use _Identity. (extract1st): Use _Select1st. * include/tr1/random (_Select): Use __conditional_type. (_To_Unsigned_Type): Use __add_unsigned. Linebreak fixups. * include/bits/locale_facets.tcc (__to_unsigned_type): Remove, use __add_unsigned. * include/tr1/random.tcc: Fixups as above. * include/tr1/unordered_map: Same. * include/tr1/hashtable: Same. * include/tr1/unordered_set: Same. * include/ext/pb_ds/detail/gp_hash_table_map_/ standard_policies.hpp: Same. * include/ext/pb_ds/detail/standard_policies.hpp: Same. * include/ext/pb_ds/detail/typelist/typelist_filter.hpp: Same. * include/ext/pb_ds/detail/binary_heap_/binary_heap_.hpp: Same. * include/ext/pb_ds/detail/type_utils.hpp: Same. * include/ext/pb_ds/trie_policy.hpp: Same. * docs/html/ext/pb_ds/string_trie_e_access_traits.html: Same. * include/bits/cpp_type_traits.h (__enable_if): Move to ext, make boolean argument first. * include/bits/locale_facets.h: Fixups for __enable_if argument and namespace switch. * include/bits/stl_algobase.h: Same. * include/bits/stl_algo.h: Same. * include/bits/stl_iterator.h: Same. * include/bits/streambuf_iterator.h: Same. * include/debug/safe_iterator.h: Same. * include/tr1/hashtable_policy.h: Same. * include/tr1/cmath: Same. * include/tr1/functional: Same. * include/tr1/functional_iterate.h: Same. * include/std/std_streambuf.h: Same. * include/c_std/std_cmath.h: Same. * testsuite/util/testsuite_tr1.h: Same. * testsuite/util/performance/assoc/multimap_common_type.hpp: Same. Co-Authored-By: Paolo Carlini <pcarlini@suse.de> Co-Authored-By: Peter Doerfler <gcc@pdoerfler.com> From-SVN: r117024
2006-09-18 15:30:56 +02:00
struct __add_unsigned
{
private:
typedef __enable_if<std::__is_integer<_Tp>::__value, _Tp> __if_type;
public:
typedef typename __if_type::__type __type;
};
type_traits.h: New. 2006-09-18 Benjamin Kosnik <bkoz@redhat.com> Peter Doerfler <gcc@pdoerfler.com> Paolo Carlini <pcarlini@suse.de> * include/ext/type_traits.h: New. (__conditional_type): New. (__numeric_traits): New. (__add_unsigned): New. (__remove_unsigned): New. (__enable_if): New. * include/Makefile.am: Add. * include/Makefile.in: Regenerate. * include/ext/pb_ds/detail/type_utils.hpp: Use ext include, remove duplicates. * include/tr1/hashtable_policy.h (IF): Use __conditional_type. (_Max_digits10): Same. (identity): Use _Identity. (extract1st): Use _Select1st. * include/tr1/random (_Select): Use __conditional_type. (_To_Unsigned_Type): Use __add_unsigned. Linebreak fixups. * include/bits/locale_facets.tcc (__to_unsigned_type): Remove, use __add_unsigned. * include/tr1/random.tcc: Fixups as above. * include/tr1/unordered_map: Same. * include/tr1/hashtable: Same. * include/tr1/unordered_set: Same. * include/ext/pb_ds/detail/gp_hash_table_map_/ standard_policies.hpp: Same. * include/ext/pb_ds/detail/standard_policies.hpp: Same. * include/ext/pb_ds/detail/typelist/typelist_filter.hpp: Same. * include/ext/pb_ds/detail/binary_heap_/binary_heap_.hpp: Same. * include/ext/pb_ds/detail/type_utils.hpp: Same. * include/ext/pb_ds/trie_policy.hpp: Same. * docs/html/ext/pb_ds/string_trie_e_access_traits.html: Same. * include/bits/cpp_type_traits.h (__enable_if): Move to ext, make boolean argument first. * include/bits/locale_facets.h: Fixups for __enable_if argument and namespace switch. * include/bits/stl_algobase.h: Same. * include/bits/stl_algo.h: Same. * include/bits/stl_iterator.h: Same. * include/bits/streambuf_iterator.h: Same. * include/debug/safe_iterator.h: Same. * include/tr1/hashtable_policy.h: Same. * include/tr1/cmath: Same. * include/tr1/functional: Same. * include/tr1/functional_iterate.h: Same. * include/std/std_streambuf.h: Same. * include/c_std/std_cmath.h: Same. * testsuite/util/testsuite_tr1.h: Same. * testsuite/util/performance/assoc/multimap_common_type.hpp: Same. Co-Authored-By: Paolo Carlini <pcarlini@suse.de> Co-Authored-By: Peter Doerfler <gcc@pdoerfler.com> From-SVN: r117024
2006-09-18 15:30:56 +02:00
template<>
struct __add_unsigned<char>
{ typedef unsigned char __type; };
template<>
struct __add_unsigned<signed char>
{ typedef unsigned char __type; };
type_traits.h: New. 2006-09-18 Benjamin Kosnik <bkoz@redhat.com> Peter Doerfler <gcc@pdoerfler.com> Paolo Carlini <pcarlini@suse.de> * include/ext/type_traits.h: New. (__conditional_type): New. (__numeric_traits): New. (__add_unsigned): New. (__remove_unsigned): New. (__enable_if): New. * include/Makefile.am: Add. * include/Makefile.in: Regenerate. * include/ext/pb_ds/detail/type_utils.hpp: Use ext include, remove duplicates. * include/tr1/hashtable_policy.h (IF): Use __conditional_type. (_Max_digits10): Same. (identity): Use _Identity. (extract1st): Use _Select1st. * include/tr1/random (_Select): Use __conditional_type. (_To_Unsigned_Type): Use __add_unsigned. Linebreak fixups. * include/bits/locale_facets.tcc (__to_unsigned_type): Remove, use __add_unsigned. * include/tr1/random.tcc: Fixups as above. * include/tr1/unordered_map: Same. * include/tr1/hashtable: Same. * include/tr1/unordered_set: Same. * include/ext/pb_ds/detail/gp_hash_table_map_/ standard_policies.hpp: Same. * include/ext/pb_ds/detail/standard_policies.hpp: Same. * include/ext/pb_ds/detail/typelist/typelist_filter.hpp: Same. * include/ext/pb_ds/detail/binary_heap_/binary_heap_.hpp: Same. * include/ext/pb_ds/detail/type_utils.hpp: Same. * include/ext/pb_ds/trie_policy.hpp: Same. * docs/html/ext/pb_ds/string_trie_e_access_traits.html: Same. * include/bits/cpp_type_traits.h (__enable_if): Move to ext, make boolean argument first. * include/bits/locale_facets.h: Fixups for __enable_if argument and namespace switch. * include/bits/stl_algobase.h: Same. * include/bits/stl_algo.h: Same. * include/bits/stl_iterator.h: Same. * include/bits/streambuf_iterator.h: Same. * include/debug/safe_iterator.h: Same. * include/tr1/hashtable_policy.h: Same. * include/tr1/cmath: Same. * include/tr1/functional: Same. * include/tr1/functional_iterate.h: Same. * include/std/std_streambuf.h: Same. * include/c_std/std_cmath.h: Same. * testsuite/util/testsuite_tr1.h: Same. * testsuite/util/performance/assoc/multimap_common_type.hpp: Same. Co-Authored-By: Paolo Carlini <pcarlini@suse.de> Co-Authored-By: Peter Doerfler <gcc@pdoerfler.com> From-SVN: r117024
2006-09-18 15:30:56 +02:00
template<>
struct __add_unsigned<short>
{ typedef unsigned short __type; };
template<>
struct __add_unsigned<int>
{ typedef unsigned int __type; };
template<>
struct __add_unsigned<long>
{ typedef unsigned long __type; };
template<>
struct __add_unsigned<long long>
{ typedef unsigned long long __type; };
// Declare but don't define.
template<>
struct __add_unsigned<bool>;
template<>
struct __add_unsigned<wchar_t>;
// Given an integral builtin type, return the corresponding signed type.
template<typename _Tp>
type_traits.h: New. 2006-09-18 Benjamin Kosnik <bkoz@redhat.com> Peter Doerfler <gcc@pdoerfler.com> Paolo Carlini <pcarlini@suse.de> * include/ext/type_traits.h: New. (__conditional_type): New. (__numeric_traits): New. (__add_unsigned): New. (__remove_unsigned): New. (__enable_if): New. * include/Makefile.am: Add. * include/Makefile.in: Regenerate. * include/ext/pb_ds/detail/type_utils.hpp: Use ext include, remove duplicates. * include/tr1/hashtable_policy.h (IF): Use __conditional_type. (_Max_digits10): Same. (identity): Use _Identity. (extract1st): Use _Select1st. * include/tr1/random (_Select): Use __conditional_type. (_To_Unsigned_Type): Use __add_unsigned. Linebreak fixups. * include/bits/locale_facets.tcc (__to_unsigned_type): Remove, use __add_unsigned. * include/tr1/random.tcc: Fixups as above. * include/tr1/unordered_map: Same. * include/tr1/hashtable: Same. * include/tr1/unordered_set: Same. * include/ext/pb_ds/detail/gp_hash_table_map_/ standard_policies.hpp: Same. * include/ext/pb_ds/detail/standard_policies.hpp: Same. * include/ext/pb_ds/detail/typelist/typelist_filter.hpp: Same. * include/ext/pb_ds/detail/binary_heap_/binary_heap_.hpp: Same. * include/ext/pb_ds/detail/type_utils.hpp: Same. * include/ext/pb_ds/trie_policy.hpp: Same. * docs/html/ext/pb_ds/string_trie_e_access_traits.html: Same. * include/bits/cpp_type_traits.h (__enable_if): Move to ext, make boolean argument first. * include/bits/locale_facets.h: Fixups for __enable_if argument and namespace switch. * include/bits/stl_algobase.h: Same. * include/bits/stl_algo.h: Same. * include/bits/stl_iterator.h: Same. * include/bits/streambuf_iterator.h: Same. * include/debug/safe_iterator.h: Same. * include/tr1/hashtable_policy.h: Same. * include/tr1/cmath: Same. * include/tr1/functional: Same. * include/tr1/functional_iterate.h: Same. * include/std/std_streambuf.h: Same. * include/c_std/std_cmath.h: Same. * testsuite/util/testsuite_tr1.h: Same. * testsuite/util/performance/assoc/multimap_common_type.hpp: Same. Co-Authored-By: Paolo Carlini <pcarlini@suse.de> Co-Authored-By: Peter Doerfler <gcc@pdoerfler.com> From-SVN: r117024
2006-09-18 15:30:56 +02:00
struct __remove_unsigned
{
private:
typedef __enable_if<std::__is_integer<_Tp>::__value, _Tp> __if_type;
public:
typedef typename __if_type::__type __type;
};
template<>
struct __remove_unsigned<char>
{ typedef signed char __type; };
type_traits.h: New. 2006-09-18 Benjamin Kosnik <bkoz@redhat.com> Peter Doerfler <gcc@pdoerfler.com> Paolo Carlini <pcarlini@suse.de> * include/ext/type_traits.h: New. (__conditional_type): New. (__numeric_traits): New. (__add_unsigned): New. (__remove_unsigned): New. (__enable_if): New. * include/Makefile.am: Add. * include/Makefile.in: Regenerate. * include/ext/pb_ds/detail/type_utils.hpp: Use ext include, remove duplicates. * include/tr1/hashtable_policy.h (IF): Use __conditional_type. (_Max_digits10): Same. (identity): Use _Identity. (extract1st): Use _Select1st. * include/tr1/random (_Select): Use __conditional_type. (_To_Unsigned_Type): Use __add_unsigned. Linebreak fixups. * include/bits/locale_facets.tcc (__to_unsigned_type): Remove, use __add_unsigned. * include/tr1/random.tcc: Fixups as above. * include/tr1/unordered_map: Same. * include/tr1/hashtable: Same. * include/tr1/unordered_set: Same. * include/ext/pb_ds/detail/gp_hash_table_map_/ standard_policies.hpp: Same. * include/ext/pb_ds/detail/standard_policies.hpp: Same. * include/ext/pb_ds/detail/typelist/typelist_filter.hpp: Same. * include/ext/pb_ds/detail/binary_heap_/binary_heap_.hpp: Same. * include/ext/pb_ds/detail/type_utils.hpp: Same. * include/ext/pb_ds/trie_policy.hpp: Same. * docs/html/ext/pb_ds/string_trie_e_access_traits.html: Same. * include/bits/cpp_type_traits.h (__enable_if): Move to ext, make boolean argument first. * include/bits/locale_facets.h: Fixups for __enable_if argument and namespace switch. * include/bits/stl_algobase.h: Same. * include/bits/stl_algo.h: Same. * include/bits/stl_iterator.h: Same. * include/bits/streambuf_iterator.h: Same. * include/debug/safe_iterator.h: Same. * include/tr1/hashtable_policy.h: Same. * include/tr1/cmath: Same. * include/tr1/functional: Same. * include/tr1/functional_iterate.h: Same. * include/std/std_streambuf.h: Same. * include/c_std/std_cmath.h: Same. * testsuite/util/testsuite_tr1.h: Same. * testsuite/util/performance/assoc/multimap_common_type.hpp: Same. Co-Authored-By: Paolo Carlini <pcarlini@suse.de> Co-Authored-By: Peter Doerfler <gcc@pdoerfler.com> From-SVN: r117024
2006-09-18 15:30:56 +02:00
template<>
struct __remove_unsigned<unsigned char>
{ typedef signed char __type; };
type_traits.h: New. 2006-09-18 Benjamin Kosnik <bkoz@redhat.com> Peter Doerfler <gcc@pdoerfler.com> Paolo Carlini <pcarlini@suse.de> * include/ext/type_traits.h: New. (__conditional_type): New. (__numeric_traits): New. (__add_unsigned): New. (__remove_unsigned): New. (__enable_if): New. * include/Makefile.am: Add. * include/Makefile.in: Regenerate. * include/ext/pb_ds/detail/type_utils.hpp: Use ext include, remove duplicates. * include/tr1/hashtable_policy.h (IF): Use __conditional_type. (_Max_digits10): Same. (identity): Use _Identity. (extract1st): Use _Select1st. * include/tr1/random (_Select): Use __conditional_type. (_To_Unsigned_Type): Use __add_unsigned. Linebreak fixups. * include/bits/locale_facets.tcc (__to_unsigned_type): Remove, use __add_unsigned. * include/tr1/random.tcc: Fixups as above. * include/tr1/unordered_map: Same. * include/tr1/hashtable: Same. * include/tr1/unordered_set: Same. * include/ext/pb_ds/detail/gp_hash_table_map_/ standard_policies.hpp: Same. * include/ext/pb_ds/detail/standard_policies.hpp: Same. * include/ext/pb_ds/detail/typelist/typelist_filter.hpp: Same. * include/ext/pb_ds/detail/binary_heap_/binary_heap_.hpp: Same. * include/ext/pb_ds/detail/type_utils.hpp: Same. * include/ext/pb_ds/trie_policy.hpp: Same. * docs/html/ext/pb_ds/string_trie_e_access_traits.html: Same. * include/bits/cpp_type_traits.h (__enable_if): Move to ext, make boolean argument first. * include/bits/locale_facets.h: Fixups for __enable_if argument and namespace switch. * include/bits/stl_algobase.h: Same. * include/bits/stl_algo.h: Same. * include/bits/stl_iterator.h: Same. * include/bits/streambuf_iterator.h: Same. * include/debug/safe_iterator.h: Same. * include/tr1/hashtable_policy.h: Same. * include/tr1/cmath: Same. * include/tr1/functional: Same. * include/tr1/functional_iterate.h: Same. * include/std/std_streambuf.h: Same. * include/c_std/std_cmath.h: Same. * testsuite/util/testsuite_tr1.h: Same. * testsuite/util/performance/assoc/multimap_common_type.hpp: Same. Co-Authored-By: Paolo Carlini <pcarlini@suse.de> Co-Authored-By: Peter Doerfler <gcc@pdoerfler.com> From-SVN: r117024
2006-09-18 15:30:56 +02:00
template<>
struct __remove_unsigned<unsigned short>
{ typedef short __type; };
template<>
struct __remove_unsigned<unsigned int>
{ typedef int __type; };
template<>
struct __remove_unsigned<unsigned long>
{ typedef long __type; };
template<>
struct __remove_unsigned<unsigned long long>
{ typedef long long __type; };
// Declare but don't define.
template<>
struct __remove_unsigned<bool>;
template<>
struct __remove_unsigned<wchar_t>;
PR libstdc++/28277 (partial: vstring bits) 2007-04-10 Paolo Carlini <pcarlini@suse.de> PR libstdc++/28277 (partial: vstring bits) * include/bits/ostream_insert.h: New. * include/Makefile.am: Add. * include/ext/vstring.h (operator<<(basic_ostream<>&, const __versa_string<>&): Forward to __ostream_insert. * include/bits/basic_string.h (operator<<(basic_ostream<>&, const string<>&)): Likewise. * include/std/ostream (operator<<(basic_ostream<>&, _CharT), operator<<(basic_ostream<char,>&, char), operator<<(basic_ostream<>&, const _CharT*), operator<<(basic_ostream<char,>&, const char*)): Likewise. * include/ext/vstring.tcc (operator<<(basic_ostream<>&, const __versa_string<>&)): Remove. (class basic_ostream): Remove friend declarations. (basic_ostream<>::_M_write(char_type, streamsize), _M_insert(const char_type*, streamsize)): Remove. * include/bits/ostream.tcc (_M_insert(const char_type*, streamsize)): Remove definition. (operator<<(basic_ostream<>&, const char*)): Use __ostream_insert. * config/abi/pre/gnu.ver: Adjust. * src/ostream-inst.cc: Add __ostream_insert instantiations. * include/bits/locale_facets.h (__pad<>::_S_pad): Remove __num parameter. * include/bits/locale_facets.tcc (__pad<>::_S_pad): Adjust. (num_put<>::_M_pad(_CharT, streamsize, ios_base&, _CharT*, const _CharT*, int&)): Likewise. * include/Makefile.in: Rebuild. * testsuite/ext/vstring/inserters_extractors/char/28277.cc: New. * testsuite/ext/vstring/inserters_extractors/wchar_t/28277.cc: New. * include/ext/vstring_util.h: Do not include the whole <locale>. * include/ext/vstring.tcc (operator>>(basic_istream<>&, __versa_string<>&, getline(basic_istream<>&, __versa_string<>&, _CharT)): Tweak to refer to ios_base as a base of istream; do not refer to non-standard types of istream. * include/bits/istream.tcc (operator>>(basic_istream<>&, _CharT*), ws(basic_istream<>&)): Do not refer to non-standard types of istream. * include/std/bitset (operator>>(std::basic_istream<>&, bitset<>&)): Avoid using basic_streambuf<>*. * include/bits/istream.tcc (operator>>(basic_istream<>&, basic_string<>&), getline(basic_istream<>&, basic_string<>&, _CharT)): Move... * include/bits/basic_string.tcc: ... here; tweak to refer to ios_base as a base of istream; do not refer to non-standard types of istream. * include/std/string: Tweak includes. * include/ext/type_traits.h (__is_null_pointer): Add. * include/ext/rc_string_base.h: Use it. * include/ext/sso_string_base.h: Likewise. * include/bits/basic_string.tcc (__is_null_pointer): Remove, use the above. * include/ext/vstring_util.h (__vstring_utility<>::_S_is_null_pointer): Remove. From-SVN: r123692
2007-04-10 12:38:50 +02:00
// For use in string and vstring.
template<typename _Type>
_GLIBCXX_CONSTEXPR
PR libstdc++/28277 (partial: vstring bits) 2007-04-10 Paolo Carlini <pcarlini@suse.de> PR libstdc++/28277 (partial: vstring bits) * include/bits/ostream_insert.h: New. * include/Makefile.am: Add. * include/ext/vstring.h (operator<<(basic_ostream<>&, const __versa_string<>&): Forward to __ostream_insert. * include/bits/basic_string.h (operator<<(basic_ostream<>&, const string<>&)): Likewise. * include/std/ostream (operator<<(basic_ostream<>&, _CharT), operator<<(basic_ostream<char,>&, char), operator<<(basic_ostream<>&, const _CharT*), operator<<(basic_ostream<char,>&, const char*)): Likewise. * include/ext/vstring.tcc (operator<<(basic_ostream<>&, const __versa_string<>&)): Remove. (class basic_ostream): Remove friend declarations. (basic_ostream<>::_M_write(char_type, streamsize), _M_insert(const char_type*, streamsize)): Remove. * include/bits/ostream.tcc (_M_insert(const char_type*, streamsize)): Remove definition. (operator<<(basic_ostream<>&, const char*)): Use __ostream_insert. * config/abi/pre/gnu.ver: Adjust. * src/ostream-inst.cc: Add __ostream_insert instantiations. * include/bits/locale_facets.h (__pad<>::_S_pad): Remove __num parameter. * include/bits/locale_facets.tcc (__pad<>::_S_pad): Adjust. (num_put<>::_M_pad(_CharT, streamsize, ios_base&, _CharT*, const _CharT*, int&)): Likewise. * include/Makefile.in: Rebuild. * testsuite/ext/vstring/inserters_extractors/char/28277.cc: New. * testsuite/ext/vstring/inserters_extractors/wchar_t/28277.cc: New. * include/ext/vstring_util.h: Do not include the whole <locale>. * include/ext/vstring.tcc (operator>>(basic_istream<>&, __versa_string<>&, getline(basic_istream<>&, __versa_string<>&, _CharT)): Tweak to refer to ios_base as a base of istream; do not refer to non-standard types of istream. * include/bits/istream.tcc (operator>>(basic_istream<>&, _CharT*), ws(basic_istream<>&)): Do not refer to non-standard types of istream. * include/std/bitset (operator>>(std::basic_istream<>&, bitset<>&)): Avoid using basic_streambuf<>*. * include/bits/istream.tcc (operator>>(basic_istream<>&, basic_string<>&), getline(basic_istream<>&, basic_string<>&, _CharT)): Move... * include/bits/basic_string.tcc: ... here; tweak to refer to ios_base as a base of istream; do not refer to non-standard types of istream. * include/std/string: Tweak includes. * include/ext/type_traits.h (__is_null_pointer): Add. * include/ext/rc_string_base.h: Use it. * include/ext/sso_string_base.h: Likewise. * include/bits/basic_string.tcc (__is_null_pointer): Remove, use the above. * include/ext/vstring_util.h (__vstring_utility<>::_S_is_null_pointer): Remove. From-SVN: r123692
2007-04-10 12:38:50 +02:00
inline bool
__is_null_pointer(_Type* __ptr)
{ return __ptr == 0; }
template<typename _Type>
_GLIBCXX_CONSTEXPR
PR libstdc++/28277 (partial: vstring bits) 2007-04-10 Paolo Carlini <pcarlini@suse.de> PR libstdc++/28277 (partial: vstring bits) * include/bits/ostream_insert.h: New. * include/Makefile.am: Add. * include/ext/vstring.h (operator<<(basic_ostream<>&, const __versa_string<>&): Forward to __ostream_insert. * include/bits/basic_string.h (operator<<(basic_ostream<>&, const string<>&)): Likewise. * include/std/ostream (operator<<(basic_ostream<>&, _CharT), operator<<(basic_ostream<char,>&, char), operator<<(basic_ostream<>&, const _CharT*), operator<<(basic_ostream<char,>&, const char*)): Likewise. * include/ext/vstring.tcc (operator<<(basic_ostream<>&, const __versa_string<>&)): Remove. (class basic_ostream): Remove friend declarations. (basic_ostream<>::_M_write(char_type, streamsize), _M_insert(const char_type*, streamsize)): Remove. * include/bits/ostream.tcc (_M_insert(const char_type*, streamsize)): Remove definition. (operator<<(basic_ostream<>&, const char*)): Use __ostream_insert. * config/abi/pre/gnu.ver: Adjust. * src/ostream-inst.cc: Add __ostream_insert instantiations. * include/bits/locale_facets.h (__pad<>::_S_pad): Remove __num parameter. * include/bits/locale_facets.tcc (__pad<>::_S_pad): Adjust. (num_put<>::_M_pad(_CharT, streamsize, ios_base&, _CharT*, const _CharT*, int&)): Likewise. * include/Makefile.in: Rebuild. * testsuite/ext/vstring/inserters_extractors/char/28277.cc: New. * testsuite/ext/vstring/inserters_extractors/wchar_t/28277.cc: New. * include/ext/vstring_util.h: Do not include the whole <locale>. * include/ext/vstring.tcc (operator>>(basic_istream<>&, __versa_string<>&, getline(basic_istream<>&, __versa_string<>&, _CharT)): Tweak to refer to ios_base as a base of istream; do not refer to non-standard types of istream. * include/bits/istream.tcc (operator>>(basic_istream<>&, _CharT*), ws(basic_istream<>&)): Do not refer to non-standard types of istream. * include/std/bitset (operator>>(std::basic_istream<>&, bitset<>&)): Avoid using basic_streambuf<>*. * include/bits/istream.tcc (operator>>(basic_istream<>&, basic_string<>&), getline(basic_istream<>&, basic_string<>&, _CharT)): Move... * include/bits/basic_string.tcc: ... here; tweak to refer to ios_base as a base of istream; do not refer to non-standard types of istream. * include/std/string: Tweak includes. * include/ext/type_traits.h (__is_null_pointer): Add. * include/ext/rc_string_base.h: Use it. * include/ext/sso_string_base.h: Likewise. * include/bits/basic_string.tcc (__is_null_pointer): Remove, use the above. * include/ext/vstring_util.h (__vstring_utility<>::_S_is_null_pointer): Remove. From-SVN: r123692
2007-04-10 12:38:50 +02:00
inline bool
__is_null_pointer(_Type)
{ return false; }
#if __cplusplus >= 201103L
constexpr bool
__is_null_pointer(std::nullptr_t)
{ return true; }
#endif
re PR libstdc++/31426 (TR1 includes do not work with -std=c++0x) 2007-05-31 Paolo Carlini <pcarlini@suse.de> PR libstdc++/31426 * include/bits/c++config: Remove namespace association bits from tr1 to std. * include/ext/type_traits.h (__promote, __promote2, __promote3, __promote4): Add. * include/bits/hashtable.h: New. * include/bits/functional_hash.h: Likewise. * include/tr1/hashtable.h: Likewise. * include/tr1_impl/random: New. * include/tr1_impl/cinttypes: Likewise. * include/tr1_impl/cstdlib: Likewise. * include/tr1_impl/unordered_map: Likewise. * include/tr1_impl/cstdio: Likewise. * include/tr1_impl/boost_shared_ptr.h: Likewise. * include/tr1_impl/cctype: Likewise. * include/tr1_impl/random.tcc: Likewise. * include/tr1_impl/tuple: Likewise. * include/tr1_impl/functional_hash.h: Likewise. * include/tr1_impl/hashtable: Likewise. * include/tr1_impl/cmath: Likewise. * include/tr1_impl/type_traitsfwd.h: Likewise. * include/tr1_impl/hashtable_policy.h: Likewise. * include/tr1_impl/cfenv: Likewise. * include/tr1_impl/unordered_set: Likewise. * include/tr1_impl/functional: Likewise. * include/tr1_impl/utility: Likewise. * include/tr1_impl/complex: Likewise. * include/tr1_impl/type_traits: Likewise. * include/tr1_impl/cwchar: Likewise. * include/tr1_impl/cstdint: Likewise. * include/tr1_impl/regex: Likewise. * include/tr1_impl/array: Likewise. * include/tr1_impl/cwctype: Likewise. * include/tr1/type_traitsfwd.h: Remove. * include/tr1/boost_shared_ptr.h: Likewise. * include/tr1/common.h: Likewise. * include/tr1/hashtable: Likewise. * include/tr1/hashtable_policy.h: Likewise. * include/tr1/random.tcc: Likewise. * include/c_global/cinttypes: Include tr1_impl/cinttypes. * include/c_global/cstdlib: Likewise for cstdlib. * include/c_global/cstdio: Likewise for cstdio. * include/c_global/cctype: Likewise for cctype. * include/c_global/cmath: Likewise for cmath. * include/c_global/cfenv: Likewise for cfenv. * include/c_global/cwchar: Likewise for cwchar. * include/c_global/cstdint: Likewise for cstdint. * include/c_global/cwctype: Likewise for cwctype. * include/tr1/cinttypes: Likewise for cinttypes. * include/tr1/cstdlib: Likewise for cstdlib. * include/tr1/cstdio: Likewise for cstdio. * include/tr1/cctype: Likewise for cctype. * include/tr1/cmath: Likewise for cmath. * include/tr1/cfenv: Likewise for cfenv. * include/tr1/cwchar: Likewise for cwchar. * include/tr1/cstdint: Likewise for cstdint. * include/tr1/cwctype: Likewise for cwctype. * include/tr1/functional_hash.h: Likewise for functional_hash. * include/std/tuple: Include tr1_impl/tuple. * include/std/utility: Likewise for utility. * include/std/type_traits: Likewise for type_traits. (is_pod): Just forward to __is_pod. (has_trivial_default_constructor): Just forward to __has_trivial_constructor. (has_trivial_copy_constructor): Just forward to __has_trivial_copy. (has_trivial_assign): Just forward to __has_trivial_assign. (has_trivial_destructor): Just forward to __has_trivial_destructor. (has_nothrow_default_constructor): Just forward to __has_nothrow_constructor. (has_nothrow_copy_constructor): Just forward to __has_nothrow_copy. (has_nothrow_assign): Just forward to __has_nothrow_assign. (is_base_of): Just forward to __is_base_of. (is_signed, is_unsigned): Implement according to the C++0x specifications. * include/std/memory: Likewise for memory. * include/std/regex: Likewise for regex. * include/std/random: Likewise for random. * include/std/unordered_map: Likewise for unordered_map. * include/std/unordered_set: Likewise for unordered_set. * include/std/functional: Likewise for functional. * include/std/complex: Likewise for complex. * include/std/array: Likewise for array. * include/tr1/tuple: Likewise for tuple. * include/tr1/utility: Likewise for utility. * include/tr1/type_traits: Likewise for type_traits * include/tr1/memory: Likewise for memory. * include/tr1/regex: Likewise for regex. * include/tr1/random: Likewise for random. * include/tr1/unordered_map: Likewise for unordered_map. * include/tr1/unordered_set: Likewise for unordered_set. * include/tr1/functional: Likewise for functional. * include/tr1/complex: Likewise for complex. * include/tr1/array: Likewise for array. * include/c_global/ctgmath: Tweak. * include/c_global/cstdarg: Likewise. * include/c_global/ctime: Likewise. * include/c_global/climits: Likewise. * include/c_global/cfloat: Likewise. * include/c_global/ccomplex: Likewise. * include/c_global/cstdbool: Likewise. * include/tr1/poly_laguerre.tcc: Tweak, don't use _GLIBCXX_TR1. * include/tr1/riemann_zeta.tcc: Likewise. * include/tr1/beta_function.tcc: Likewise. * include/tr1/exp_integral.tcc: Likewise. * include/tr1/hypergeometric.tcc: Likewise. * include/tr1/modified_bessel_func.tcc: Likewise. * include/tr1/legendre_function.tcc: Likewise. * include/tr1/special_function_util.h: Likewise. * include/tr1/bessel_function.tcc: Likewise. * include/tr1/poly_hermite.tcc: Likewise. * include/tr1/ell_integral.tcc: Likewise. * include/tr1/gamma.tcc: Likewise. * include/tr1/stdlib.h: Likewise. * include/tr1/math.h: Likewise. * include/tr1/complex.h: Minor tweaks. * include/tr1/wctype.h: Likewise. * include/tr1/wchar.h: Likewise. * include/tr1/inttypes.h: Likewise. * include/tr1/tgmath.h: Likewise. * include/tr1/cstdbool: Likewise. * include/tr1/cfloat: Likewise. * include/tr1/ccomplex: Likewise. * include/tr1/ctime: Likewise. * include/tr1/climits: Likewise. * include/tr1/ctgmath: Likewise. * include/tr1/cstdarg: Likewise. * testsuite/tr1/headers.cc: Move... * testsuite/tr1/headers/all.cc: ... here. * testsuite/tr1/using_namespace_std_tr1.cc: Move... * testsuite/tr1/headers/c++200x/using_namespace_std_tr1.cc: ... here. * testsuite/tr1/headers/using_namespace_std_tr1.cc ... here. * testsuite/tr1/headers/c++200x/using_namespace_std_tr1.cc: New. * testsuite/20_util/tuple/requirements/explicit_instantiation.cc: Adjust namespace. * testsuite/20_util/has_nothrow_copy_constructor/value.cc: Adjust to the C++0x requirements. * testsuite/20_util/has_nothrow_default_constructor/value.cc: Likewise. * testsuite/20_util/has_trivial_copy_constructor/value.cc: Likewise. * testsuite/20_util/has_trivial_default_constructor/value.cc: Likewise. * testsuite/20_util/make_signed/requirements/typedefs_neg.cc: Adjust dg-error lines. * testsuite/20_util/make_unsigned/requirements/typedefs_neg.cc: Likewise. * testsuite/20_util/headers/type_traits/types_std_c++0x_neg.cc: Un-xfail. * testsuite/20_util/is_signed/value.cc: New. * testsuite/20_util/is_signed/requirements/typedefs.cc: Likewise. * testsuite/20_util/is_signed/requirements/explicit_instantiation.cc: Likewise. * testsuite/20_util/is_unsigned/value.cc: Likewise.. * testsuite/20_util/is_unsigned/requirements/typedefs.cc: Likewise. * testsuite/20_util/is_unsigned/requirements/explicit_instantiation.cc: Likewise. * include/Makefile.am: Adjust. * include/Makefile.in: Regenerate. From-SVN: r125244
2007-06-01 01:37:56 +02:00
// For arithmetic promotions in <complex> and <cmath>
re PR libstdc++/31426 (TR1 includes do not work with -std=c++0x) 2007-05-31 Paolo Carlini <pcarlini@suse.de> PR libstdc++/31426 * include/bits/c++config: Remove namespace association bits from tr1 to std. * include/ext/type_traits.h (__promote, __promote2, __promote3, __promote4): Add. * include/bits/hashtable.h: New. * include/bits/functional_hash.h: Likewise. * include/tr1/hashtable.h: Likewise. * include/tr1_impl/random: New. * include/tr1_impl/cinttypes: Likewise. * include/tr1_impl/cstdlib: Likewise. * include/tr1_impl/unordered_map: Likewise. * include/tr1_impl/cstdio: Likewise. * include/tr1_impl/boost_shared_ptr.h: Likewise. * include/tr1_impl/cctype: Likewise. * include/tr1_impl/random.tcc: Likewise. * include/tr1_impl/tuple: Likewise. * include/tr1_impl/functional_hash.h: Likewise. * include/tr1_impl/hashtable: Likewise. * include/tr1_impl/cmath: Likewise. * include/tr1_impl/type_traitsfwd.h: Likewise. * include/tr1_impl/hashtable_policy.h: Likewise. * include/tr1_impl/cfenv: Likewise. * include/tr1_impl/unordered_set: Likewise. * include/tr1_impl/functional: Likewise. * include/tr1_impl/utility: Likewise. * include/tr1_impl/complex: Likewise. * include/tr1_impl/type_traits: Likewise. * include/tr1_impl/cwchar: Likewise. * include/tr1_impl/cstdint: Likewise. * include/tr1_impl/regex: Likewise. * include/tr1_impl/array: Likewise. * include/tr1_impl/cwctype: Likewise. * include/tr1/type_traitsfwd.h: Remove. * include/tr1/boost_shared_ptr.h: Likewise. * include/tr1/common.h: Likewise. * include/tr1/hashtable: Likewise. * include/tr1/hashtable_policy.h: Likewise. * include/tr1/random.tcc: Likewise. * include/c_global/cinttypes: Include tr1_impl/cinttypes. * include/c_global/cstdlib: Likewise for cstdlib. * include/c_global/cstdio: Likewise for cstdio. * include/c_global/cctype: Likewise for cctype. * include/c_global/cmath: Likewise for cmath. * include/c_global/cfenv: Likewise for cfenv. * include/c_global/cwchar: Likewise for cwchar. * include/c_global/cstdint: Likewise for cstdint. * include/c_global/cwctype: Likewise for cwctype. * include/tr1/cinttypes: Likewise for cinttypes. * include/tr1/cstdlib: Likewise for cstdlib. * include/tr1/cstdio: Likewise for cstdio. * include/tr1/cctype: Likewise for cctype. * include/tr1/cmath: Likewise for cmath. * include/tr1/cfenv: Likewise for cfenv. * include/tr1/cwchar: Likewise for cwchar. * include/tr1/cstdint: Likewise for cstdint. * include/tr1/cwctype: Likewise for cwctype. * include/tr1/functional_hash.h: Likewise for functional_hash. * include/std/tuple: Include tr1_impl/tuple. * include/std/utility: Likewise for utility. * include/std/type_traits: Likewise for type_traits. (is_pod): Just forward to __is_pod. (has_trivial_default_constructor): Just forward to __has_trivial_constructor. (has_trivial_copy_constructor): Just forward to __has_trivial_copy. (has_trivial_assign): Just forward to __has_trivial_assign. (has_trivial_destructor): Just forward to __has_trivial_destructor. (has_nothrow_default_constructor): Just forward to __has_nothrow_constructor. (has_nothrow_copy_constructor): Just forward to __has_nothrow_copy. (has_nothrow_assign): Just forward to __has_nothrow_assign. (is_base_of): Just forward to __is_base_of. (is_signed, is_unsigned): Implement according to the C++0x specifications. * include/std/memory: Likewise for memory. * include/std/regex: Likewise for regex. * include/std/random: Likewise for random. * include/std/unordered_map: Likewise for unordered_map. * include/std/unordered_set: Likewise for unordered_set. * include/std/functional: Likewise for functional. * include/std/complex: Likewise for complex. * include/std/array: Likewise for array. * include/tr1/tuple: Likewise for tuple. * include/tr1/utility: Likewise for utility. * include/tr1/type_traits: Likewise for type_traits * include/tr1/memory: Likewise for memory. * include/tr1/regex: Likewise for regex. * include/tr1/random: Likewise for random. * include/tr1/unordered_map: Likewise for unordered_map. * include/tr1/unordered_set: Likewise for unordered_set. * include/tr1/functional: Likewise for functional. * include/tr1/complex: Likewise for complex. * include/tr1/array: Likewise for array. * include/c_global/ctgmath: Tweak. * include/c_global/cstdarg: Likewise. * include/c_global/ctime: Likewise. * include/c_global/climits: Likewise. * include/c_global/cfloat: Likewise. * include/c_global/ccomplex: Likewise. * include/c_global/cstdbool: Likewise. * include/tr1/poly_laguerre.tcc: Tweak, don't use _GLIBCXX_TR1. * include/tr1/riemann_zeta.tcc: Likewise. * include/tr1/beta_function.tcc: Likewise. * include/tr1/exp_integral.tcc: Likewise. * include/tr1/hypergeometric.tcc: Likewise. * include/tr1/modified_bessel_func.tcc: Likewise. * include/tr1/legendre_function.tcc: Likewise. * include/tr1/special_function_util.h: Likewise. * include/tr1/bessel_function.tcc: Likewise. * include/tr1/poly_hermite.tcc: Likewise. * include/tr1/ell_integral.tcc: Likewise. * include/tr1/gamma.tcc: Likewise. * include/tr1/stdlib.h: Likewise. * include/tr1/math.h: Likewise. * include/tr1/complex.h: Minor tweaks. * include/tr1/wctype.h: Likewise. * include/tr1/wchar.h: Likewise. * include/tr1/inttypes.h: Likewise. * include/tr1/tgmath.h: Likewise. * include/tr1/cstdbool: Likewise. * include/tr1/cfloat: Likewise. * include/tr1/ccomplex: Likewise. * include/tr1/ctime: Likewise. * include/tr1/climits: Likewise. * include/tr1/ctgmath: Likewise. * include/tr1/cstdarg: Likewise. * testsuite/tr1/headers.cc: Move... * testsuite/tr1/headers/all.cc: ... here. * testsuite/tr1/using_namespace_std_tr1.cc: Move... * testsuite/tr1/headers/c++200x/using_namespace_std_tr1.cc: ... here. * testsuite/tr1/headers/using_namespace_std_tr1.cc ... here. * testsuite/tr1/headers/c++200x/using_namespace_std_tr1.cc: New. * testsuite/20_util/tuple/requirements/explicit_instantiation.cc: Adjust namespace. * testsuite/20_util/has_nothrow_copy_constructor/value.cc: Adjust to the C++0x requirements. * testsuite/20_util/has_nothrow_default_constructor/value.cc: Likewise. * testsuite/20_util/has_trivial_copy_constructor/value.cc: Likewise. * testsuite/20_util/has_trivial_default_constructor/value.cc: Likewise. * testsuite/20_util/make_signed/requirements/typedefs_neg.cc: Adjust dg-error lines. * testsuite/20_util/make_unsigned/requirements/typedefs_neg.cc: Likewise. * testsuite/20_util/headers/type_traits/types_std_c++0x_neg.cc: Un-xfail. * testsuite/20_util/is_signed/value.cc: New. * testsuite/20_util/is_signed/requirements/typedefs.cc: Likewise. * testsuite/20_util/is_signed/requirements/explicit_instantiation.cc: Likewise. * testsuite/20_util/is_unsigned/value.cc: Likewise.. * testsuite/20_util/is_unsigned/requirements/typedefs.cc: Likewise. * testsuite/20_util/is_unsigned/requirements/explicit_instantiation.cc: Likewise. * include/Makefile.am: Adjust. * include/Makefile.in: Regenerate. From-SVN: r125244
2007-06-01 01:37:56 +02:00
template<typename _Tp, bool = std::__is_integer<_Tp>::__value>
struct __promote
{ typedef double __type; };
// No nested __type member for non-integer non-floating point types,
// allows this type to be used for SFINAE to constrain overloads in
// <cmath> and <complex> to only the intended types.
re PR libstdc++/31426 (TR1 includes do not work with -std=c++0x) 2007-05-31 Paolo Carlini <pcarlini@suse.de> PR libstdc++/31426 * include/bits/c++config: Remove namespace association bits from tr1 to std. * include/ext/type_traits.h (__promote, __promote2, __promote3, __promote4): Add. * include/bits/hashtable.h: New. * include/bits/functional_hash.h: Likewise. * include/tr1/hashtable.h: Likewise. * include/tr1_impl/random: New. * include/tr1_impl/cinttypes: Likewise. * include/tr1_impl/cstdlib: Likewise. * include/tr1_impl/unordered_map: Likewise. * include/tr1_impl/cstdio: Likewise. * include/tr1_impl/boost_shared_ptr.h: Likewise. * include/tr1_impl/cctype: Likewise. * include/tr1_impl/random.tcc: Likewise. * include/tr1_impl/tuple: Likewise. * include/tr1_impl/functional_hash.h: Likewise. * include/tr1_impl/hashtable: Likewise. * include/tr1_impl/cmath: Likewise. * include/tr1_impl/type_traitsfwd.h: Likewise. * include/tr1_impl/hashtable_policy.h: Likewise. * include/tr1_impl/cfenv: Likewise. * include/tr1_impl/unordered_set: Likewise. * include/tr1_impl/functional: Likewise. * include/tr1_impl/utility: Likewise. * include/tr1_impl/complex: Likewise. * include/tr1_impl/type_traits: Likewise. * include/tr1_impl/cwchar: Likewise. * include/tr1_impl/cstdint: Likewise. * include/tr1_impl/regex: Likewise. * include/tr1_impl/array: Likewise. * include/tr1_impl/cwctype: Likewise. * include/tr1/type_traitsfwd.h: Remove. * include/tr1/boost_shared_ptr.h: Likewise. * include/tr1/common.h: Likewise. * include/tr1/hashtable: Likewise. * include/tr1/hashtable_policy.h: Likewise. * include/tr1/random.tcc: Likewise. * include/c_global/cinttypes: Include tr1_impl/cinttypes. * include/c_global/cstdlib: Likewise for cstdlib. * include/c_global/cstdio: Likewise for cstdio. * include/c_global/cctype: Likewise for cctype. * include/c_global/cmath: Likewise for cmath. * include/c_global/cfenv: Likewise for cfenv. * include/c_global/cwchar: Likewise for cwchar. * include/c_global/cstdint: Likewise for cstdint. * include/c_global/cwctype: Likewise for cwctype. * include/tr1/cinttypes: Likewise for cinttypes. * include/tr1/cstdlib: Likewise for cstdlib. * include/tr1/cstdio: Likewise for cstdio. * include/tr1/cctype: Likewise for cctype. * include/tr1/cmath: Likewise for cmath. * include/tr1/cfenv: Likewise for cfenv. * include/tr1/cwchar: Likewise for cwchar. * include/tr1/cstdint: Likewise for cstdint. * include/tr1/cwctype: Likewise for cwctype. * include/tr1/functional_hash.h: Likewise for functional_hash. * include/std/tuple: Include tr1_impl/tuple. * include/std/utility: Likewise for utility. * include/std/type_traits: Likewise for type_traits. (is_pod): Just forward to __is_pod. (has_trivial_default_constructor): Just forward to __has_trivial_constructor. (has_trivial_copy_constructor): Just forward to __has_trivial_copy. (has_trivial_assign): Just forward to __has_trivial_assign. (has_trivial_destructor): Just forward to __has_trivial_destructor. (has_nothrow_default_constructor): Just forward to __has_nothrow_constructor. (has_nothrow_copy_constructor): Just forward to __has_nothrow_copy. (has_nothrow_assign): Just forward to __has_nothrow_assign. (is_base_of): Just forward to __is_base_of. (is_signed, is_unsigned): Implement according to the C++0x specifications. * include/std/memory: Likewise for memory. * include/std/regex: Likewise for regex. * include/std/random: Likewise for random. * include/std/unordered_map: Likewise for unordered_map. * include/std/unordered_set: Likewise for unordered_set. * include/std/functional: Likewise for functional. * include/std/complex: Likewise for complex. * include/std/array: Likewise for array. * include/tr1/tuple: Likewise for tuple. * include/tr1/utility: Likewise for utility. * include/tr1/type_traits: Likewise for type_traits * include/tr1/memory: Likewise for memory. * include/tr1/regex: Likewise for regex. * include/tr1/random: Likewise for random. * include/tr1/unordered_map: Likewise for unordered_map. * include/tr1/unordered_set: Likewise for unordered_set. * include/tr1/functional: Likewise for functional. * include/tr1/complex: Likewise for complex. * include/tr1/array: Likewise for array. * include/c_global/ctgmath: Tweak. * include/c_global/cstdarg: Likewise. * include/c_global/ctime: Likewise. * include/c_global/climits: Likewise. * include/c_global/cfloat: Likewise. * include/c_global/ccomplex: Likewise. * include/c_global/cstdbool: Likewise. * include/tr1/poly_laguerre.tcc: Tweak, don't use _GLIBCXX_TR1. * include/tr1/riemann_zeta.tcc: Likewise. * include/tr1/beta_function.tcc: Likewise. * include/tr1/exp_integral.tcc: Likewise. * include/tr1/hypergeometric.tcc: Likewise. * include/tr1/modified_bessel_func.tcc: Likewise. * include/tr1/legendre_function.tcc: Likewise. * include/tr1/special_function_util.h: Likewise. * include/tr1/bessel_function.tcc: Likewise. * include/tr1/poly_hermite.tcc: Likewise. * include/tr1/ell_integral.tcc: Likewise. * include/tr1/gamma.tcc: Likewise. * include/tr1/stdlib.h: Likewise. * include/tr1/math.h: Likewise. * include/tr1/complex.h: Minor tweaks. * include/tr1/wctype.h: Likewise. * include/tr1/wchar.h: Likewise. * include/tr1/inttypes.h: Likewise. * include/tr1/tgmath.h: Likewise. * include/tr1/cstdbool: Likewise. * include/tr1/cfloat: Likewise. * include/tr1/ccomplex: Likewise. * include/tr1/ctime: Likewise. * include/tr1/climits: Likewise. * include/tr1/ctgmath: Likewise. * include/tr1/cstdarg: Likewise. * testsuite/tr1/headers.cc: Move... * testsuite/tr1/headers/all.cc: ... here. * testsuite/tr1/using_namespace_std_tr1.cc: Move... * testsuite/tr1/headers/c++200x/using_namespace_std_tr1.cc: ... here. * testsuite/tr1/headers/using_namespace_std_tr1.cc ... here. * testsuite/tr1/headers/c++200x/using_namespace_std_tr1.cc: New. * testsuite/20_util/tuple/requirements/explicit_instantiation.cc: Adjust namespace. * testsuite/20_util/has_nothrow_copy_constructor/value.cc: Adjust to the C++0x requirements. * testsuite/20_util/has_nothrow_default_constructor/value.cc: Likewise. * testsuite/20_util/has_trivial_copy_constructor/value.cc: Likewise. * testsuite/20_util/has_trivial_default_constructor/value.cc: Likewise. * testsuite/20_util/make_signed/requirements/typedefs_neg.cc: Adjust dg-error lines. * testsuite/20_util/make_unsigned/requirements/typedefs_neg.cc: Likewise. * testsuite/20_util/headers/type_traits/types_std_c++0x_neg.cc: Un-xfail. * testsuite/20_util/is_signed/value.cc: New. * testsuite/20_util/is_signed/requirements/typedefs.cc: Likewise. * testsuite/20_util/is_signed/requirements/explicit_instantiation.cc: Likewise. * testsuite/20_util/is_unsigned/value.cc: Likewise.. * testsuite/20_util/is_unsigned/requirements/typedefs.cc: Likewise. * testsuite/20_util/is_unsigned/requirements/explicit_instantiation.cc: Likewise. * include/Makefile.am: Adjust. * include/Makefile.in: Regenerate. From-SVN: r125244
2007-06-01 01:37:56 +02:00
template<typename _Tp>
struct __promote<_Tp, false>
{ };
template<>
struct __promote<long double>
{ typedef long double __type; };
template<>
struct __promote<double>
{ typedef double __type; };
template<>
struct __promote<float>
{ typedef float __type; };
re PR libstdc++/31426 (TR1 includes do not work with -std=c++0x) 2007-05-31 Paolo Carlini <pcarlini@suse.de> PR libstdc++/31426 * include/bits/c++config: Remove namespace association bits from tr1 to std. * include/ext/type_traits.h (__promote, __promote2, __promote3, __promote4): Add. * include/bits/hashtable.h: New. * include/bits/functional_hash.h: Likewise. * include/tr1/hashtable.h: Likewise. * include/tr1_impl/random: New. * include/tr1_impl/cinttypes: Likewise. * include/tr1_impl/cstdlib: Likewise. * include/tr1_impl/unordered_map: Likewise. * include/tr1_impl/cstdio: Likewise. * include/tr1_impl/boost_shared_ptr.h: Likewise. * include/tr1_impl/cctype: Likewise. * include/tr1_impl/random.tcc: Likewise. * include/tr1_impl/tuple: Likewise. * include/tr1_impl/functional_hash.h: Likewise. * include/tr1_impl/hashtable: Likewise. * include/tr1_impl/cmath: Likewise. * include/tr1_impl/type_traitsfwd.h: Likewise. * include/tr1_impl/hashtable_policy.h: Likewise. * include/tr1_impl/cfenv: Likewise. * include/tr1_impl/unordered_set: Likewise. * include/tr1_impl/functional: Likewise. * include/tr1_impl/utility: Likewise. * include/tr1_impl/complex: Likewise. * include/tr1_impl/type_traits: Likewise. * include/tr1_impl/cwchar: Likewise. * include/tr1_impl/cstdint: Likewise. * include/tr1_impl/regex: Likewise. * include/tr1_impl/array: Likewise. * include/tr1_impl/cwctype: Likewise. * include/tr1/type_traitsfwd.h: Remove. * include/tr1/boost_shared_ptr.h: Likewise. * include/tr1/common.h: Likewise. * include/tr1/hashtable: Likewise. * include/tr1/hashtable_policy.h: Likewise. * include/tr1/random.tcc: Likewise. * include/c_global/cinttypes: Include tr1_impl/cinttypes. * include/c_global/cstdlib: Likewise for cstdlib. * include/c_global/cstdio: Likewise for cstdio. * include/c_global/cctype: Likewise for cctype. * include/c_global/cmath: Likewise for cmath. * include/c_global/cfenv: Likewise for cfenv. * include/c_global/cwchar: Likewise for cwchar. * include/c_global/cstdint: Likewise for cstdint. * include/c_global/cwctype: Likewise for cwctype. * include/tr1/cinttypes: Likewise for cinttypes. * include/tr1/cstdlib: Likewise for cstdlib. * include/tr1/cstdio: Likewise for cstdio. * include/tr1/cctype: Likewise for cctype. * include/tr1/cmath: Likewise for cmath. * include/tr1/cfenv: Likewise for cfenv. * include/tr1/cwchar: Likewise for cwchar. * include/tr1/cstdint: Likewise for cstdint. * include/tr1/cwctype: Likewise for cwctype. * include/tr1/functional_hash.h: Likewise for functional_hash. * include/std/tuple: Include tr1_impl/tuple. * include/std/utility: Likewise for utility. * include/std/type_traits: Likewise for type_traits. (is_pod): Just forward to __is_pod. (has_trivial_default_constructor): Just forward to __has_trivial_constructor. (has_trivial_copy_constructor): Just forward to __has_trivial_copy. (has_trivial_assign): Just forward to __has_trivial_assign. (has_trivial_destructor): Just forward to __has_trivial_destructor. (has_nothrow_default_constructor): Just forward to __has_nothrow_constructor. (has_nothrow_copy_constructor): Just forward to __has_nothrow_copy. (has_nothrow_assign): Just forward to __has_nothrow_assign. (is_base_of): Just forward to __is_base_of. (is_signed, is_unsigned): Implement according to the C++0x specifications. * include/std/memory: Likewise for memory. * include/std/regex: Likewise for regex. * include/std/random: Likewise for random. * include/std/unordered_map: Likewise for unordered_map. * include/std/unordered_set: Likewise for unordered_set. * include/std/functional: Likewise for functional. * include/std/complex: Likewise for complex. * include/std/array: Likewise for array. * include/tr1/tuple: Likewise for tuple. * include/tr1/utility: Likewise for utility. * include/tr1/type_traits: Likewise for type_traits * include/tr1/memory: Likewise for memory. * include/tr1/regex: Likewise for regex. * include/tr1/random: Likewise for random. * include/tr1/unordered_map: Likewise for unordered_map. * include/tr1/unordered_set: Likewise for unordered_set. * include/tr1/functional: Likewise for functional. * include/tr1/complex: Likewise for complex. * include/tr1/array: Likewise for array. * include/c_global/ctgmath: Tweak. * include/c_global/cstdarg: Likewise. * include/c_global/ctime: Likewise. * include/c_global/climits: Likewise. * include/c_global/cfloat: Likewise. * include/c_global/ccomplex: Likewise. * include/c_global/cstdbool: Likewise. * include/tr1/poly_laguerre.tcc: Tweak, don't use _GLIBCXX_TR1. * include/tr1/riemann_zeta.tcc: Likewise. * include/tr1/beta_function.tcc: Likewise. * include/tr1/exp_integral.tcc: Likewise. * include/tr1/hypergeometric.tcc: Likewise. * include/tr1/modified_bessel_func.tcc: Likewise. * include/tr1/legendre_function.tcc: Likewise. * include/tr1/special_function_util.h: Likewise. * include/tr1/bessel_function.tcc: Likewise. * include/tr1/poly_hermite.tcc: Likewise. * include/tr1/ell_integral.tcc: Likewise. * include/tr1/gamma.tcc: Likewise. * include/tr1/stdlib.h: Likewise. * include/tr1/math.h: Likewise. * include/tr1/complex.h: Minor tweaks. * include/tr1/wctype.h: Likewise. * include/tr1/wchar.h: Likewise. * include/tr1/inttypes.h: Likewise. * include/tr1/tgmath.h: Likewise. * include/tr1/cstdbool: Likewise. * include/tr1/cfloat: Likewise. * include/tr1/ccomplex: Likewise. * include/tr1/ctime: Likewise. * include/tr1/climits: Likewise. * include/tr1/ctgmath: Likewise. * include/tr1/cstdarg: Likewise. * testsuite/tr1/headers.cc: Move... * testsuite/tr1/headers/all.cc: ... here. * testsuite/tr1/using_namespace_std_tr1.cc: Move... * testsuite/tr1/headers/c++200x/using_namespace_std_tr1.cc: ... here. * testsuite/tr1/headers/using_namespace_std_tr1.cc ... here. * testsuite/tr1/headers/c++200x/using_namespace_std_tr1.cc: New. * testsuite/20_util/tuple/requirements/explicit_instantiation.cc: Adjust namespace. * testsuite/20_util/has_nothrow_copy_constructor/value.cc: Adjust to the C++0x requirements. * testsuite/20_util/has_nothrow_default_constructor/value.cc: Likewise. * testsuite/20_util/has_trivial_copy_constructor/value.cc: Likewise. * testsuite/20_util/has_trivial_default_constructor/value.cc: Likewise. * testsuite/20_util/make_signed/requirements/typedefs_neg.cc: Adjust dg-error lines. * testsuite/20_util/make_unsigned/requirements/typedefs_neg.cc: Likewise. * testsuite/20_util/headers/type_traits/types_std_c++0x_neg.cc: Un-xfail. * testsuite/20_util/is_signed/value.cc: New. * testsuite/20_util/is_signed/requirements/typedefs.cc: Likewise. * testsuite/20_util/is_signed/requirements/explicit_instantiation.cc: Likewise. * testsuite/20_util/is_unsigned/value.cc: Likewise.. * testsuite/20_util/is_unsigned/requirements/typedefs.cc: Likewise. * testsuite/20_util/is_unsigned/requirements/explicit_instantiation.cc: Likewise. * include/Makefile.am: Adjust. * include/Makefile.in: Regenerate. From-SVN: r125244
2007-06-01 01:37:56 +02:00
#if __cpp_fold_expressions
template<typename... _Tp>
using __promoted_t = decltype((typename __promote<_Tp>::__type(0) + ...));
// Deducing the promoted type is done by __promoted_t<_Tp...>,
// then __promote is used to provide the nested __type member.
template<typename _Tp, typename _Up>
using __promote_2 = __promote<__promoted_t<_Tp, _Up>>;
template<typename _Tp, typename _Up, typename _Vp>
using __promote_3 = __promote<__promoted_t<_Tp, _Up, _Vp>>;
template<typename _Tp, typename _Up, typename _Vp, typename _Wp>
using __promote_4 = __promote<__promoted_t<_Tp, _Up, _Vp, _Wp>>;
#else
template<typename _Tp, typename _Up,
typename _Tp2 = typename __promote<_Tp>::__type,
typename _Up2 = typename __promote<_Up>::__type>
re PR libstdc++/31426 (TR1 includes do not work with -std=c++0x) 2007-05-31 Paolo Carlini <pcarlini@suse.de> PR libstdc++/31426 * include/bits/c++config: Remove namespace association bits from tr1 to std. * include/ext/type_traits.h (__promote, __promote2, __promote3, __promote4): Add. * include/bits/hashtable.h: New. * include/bits/functional_hash.h: Likewise. * include/tr1/hashtable.h: Likewise. * include/tr1_impl/random: New. * include/tr1_impl/cinttypes: Likewise. * include/tr1_impl/cstdlib: Likewise. * include/tr1_impl/unordered_map: Likewise. * include/tr1_impl/cstdio: Likewise. * include/tr1_impl/boost_shared_ptr.h: Likewise. * include/tr1_impl/cctype: Likewise. * include/tr1_impl/random.tcc: Likewise. * include/tr1_impl/tuple: Likewise. * include/tr1_impl/functional_hash.h: Likewise. * include/tr1_impl/hashtable: Likewise. * include/tr1_impl/cmath: Likewise. * include/tr1_impl/type_traitsfwd.h: Likewise. * include/tr1_impl/hashtable_policy.h: Likewise. * include/tr1_impl/cfenv: Likewise. * include/tr1_impl/unordered_set: Likewise. * include/tr1_impl/functional: Likewise. * include/tr1_impl/utility: Likewise. * include/tr1_impl/complex: Likewise. * include/tr1_impl/type_traits: Likewise. * include/tr1_impl/cwchar: Likewise. * include/tr1_impl/cstdint: Likewise. * include/tr1_impl/regex: Likewise. * include/tr1_impl/array: Likewise. * include/tr1_impl/cwctype: Likewise. * include/tr1/type_traitsfwd.h: Remove. * include/tr1/boost_shared_ptr.h: Likewise. * include/tr1/common.h: Likewise. * include/tr1/hashtable: Likewise. * include/tr1/hashtable_policy.h: Likewise. * include/tr1/random.tcc: Likewise. * include/c_global/cinttypes: Include tr1_impl/cinttypes. * include/c_global/cstdlib: Likewise for cstdlib. * include/c_global/cstdio: Likewise for cstdio. * include/c_global/cctype: Likewise for cctype. * include/c_global/cmath: Likewise for cmath. * include/c_global/cfenv: Likewise for cfenv. * include/c_global/cwchar: Likewise for cwchar. * include/c_global/cstdint: Likewise for cstdint. * include/c_global/cwctype: Likewise for cwctype. * include/tr1/cinttypes: Likewise for cinttypes. * include/tr1/cstdlib: Likewise for cstdlib. * include/tr1/cstdio: Likewise for cstdio. * include/tr1/cctype: Likewise for cctype. * include/tr1/cmath: Likewise for cmath. * include/tr1/cfenv: Likewise for cfenv. * include/tr1/cwchar: Likewise for cwchar. * include/tr1/cstdint: Likewise for cstdint. * include/tr1/cwctype: Likewise for cwctype. * include/tr1/functional_hash.h: Likewise for functional_hash. * include/std/tuple: Include tr1_impl/tuple. * include/std/utility: Likewise for utility. * include/std/type_traits: Likewise for type_traits. (is_pod): Just forward to __is_pod. (has_trivial_default_constructor): Just forward to __has_trivial_constructor. (has_trivial_copy_constructor): Just forward to __has_trivial_copy. (has_trivial_assign): Just forward to __has_trivial_assign. (has_trivial_destructor): Just forward to __has_trivial_destructor. (has_nothrow_default_constructor): Just forward to __has_nothrow_constructor. (has_nothrow_copy_constructor): Just forward to __has_nothrow_copy. (has_nothrow_assign): Just forward to __has_nothrow_assign. (is_base_of): Just forward to __is_base_of. (is_signed, is_unsigned): Implement according to the C++0x specifications. * include/std/memory: Likewise for memory. * include/std/regex: Likewise for regex. * include/std/random: Likewise for random. * include/std/unordered_map: Likewise for unordered_map. * include/std/unordered_set: Likewise for unordered_set. * include/std/functional: Likewise for functional. * include/std/complex: Likewise for complex. * include/std/array: Likewise for array. * include/tr1/tuple: Likewise for tuple. * include/tr1/utility: Likewise for utility. * include/tr1/type_traits: Likewise for type_traits * include/tr1/memory: Likewise for memory. * include/tr1/regex: Likewise for regex. * include/tr1/random: Likewise for random. * include/tr1/unordered_map: Likewise for unordered_map. * include/tr1/unordered_set: Likewise for unordered_set. * include/tr1/functional: Likewise for functional. * include/tr1/complex: Likewise for complex. * include/tr1/array: Likewise for array. * include/c_global/ctgmath: Tweak. * include/c_global/cstdarg: Likewise. * include/c_global/ctime: Likewise. * include/c_global/climits: Likewise. * include/c_global/cfloat: Likewise. * include/c_global/ccomplex: Likewise. * include/c_global/cstdbool: Likewise. * include/tr1/poly_laguerre.tcc: Tweak, don't use _GLIBCXX_TR1. * include/tr1/riemann_zeta.tcc: Likewise. * include/tr1/beta_function.tcc: Likewise. * include/tr1/exp_integral.tcc: Likewise. * include/tr1/hypergeometric.tcc: Likewise. * include/tr1/modified_bessel_func.tcc: Likewise. * include/tr1/legendre_function.tcc: Likewise. * include/tr1/special_function_util.h: Likewise. * include/tr1/bessel_function.tcc: Likewise. * include/tr1/poly_hermite.tcc: Likewise. * include/tr1/ell_integral.tcc: Likewise. * include/tr1/gamma.tcc: Likewise. * include/tr1/stdlib.h: Likewise. * include/tr1/math.h: Likewise. * include/tr1/complex.h: Minor tweaks. * include/tr1/wctype.h: Likewise. * include/tr1/wchar.h: Likewise. * include/tr1/inttypes.h: Likewise. * include/tr1/tgmath.h: Likewise. * include/tr1/cstdbool: Likewise. * include/tr1/cfloat: Likewise. * include/tr1/ccomplex: Likewise. * include/tr1/ctime: Likewise. * include/tr1/climits: Likewise. * include/tr1/ctgmath: Likewise. * include/tr1/cstdarg: Likewise. * testsuite/tr1/headers.cc: Move... * testsuite/tr1/headers/all.cc: ... here. * testsuite/tr1/using_namespace_std_tr1.cc: Move... * testsuite/tr1/headers/c++200x/using_namespace_std_tr1.cc: ... here. * testsuite/tr1/headers/using_namespace_std_tr1.cc ... here. * testsuite/tr1/headers/c++200x/using_namespace_std_tr1.cc: New. * testsuite/20_util/tuple/requirements/explicit_instantiation.cc: Adjust namespace. * testsuite/20_util/has_nothrow_copy_constructor/value.cc: Adjust to the C++0x requirements. * testsuite/20_util/has_nothrow_default_constructor/value.cc: Likewise. * testsuite/20_util/has_trivial_copy_constructor/value.cc: Likewise. * testsuite/20_util/has_trivial_default_constructor/value.cc: Likewise. * testsuite/20_util/make_signed/requirements/typedefs_neg.cc: Adjust dg-error lines. * testsuite/20_util/make_unsigned/requirements/typedefs_neg.cc: Likewise. * testsuite/20_util/headers/type_traits/types_std_c++0x_neg.cc: Un-xfail. * testsuite/20_util/is_signed/value.cc: New. * testsuite/20_util/is_signed/requirements/typedefs.cc: Likewise. * testsuite/20_util/is_signed/requirements/explicit_instantiation.cc: Likewise. * testsuite/20_util/is_unsigned/value.cc: Likewise.. * testsuite/20_util/is_unsigned/requirements/typedefs.cc: Likewise. * testsuite/20_util/is_unsigned/requirements/explicit_instantiation.cc: Likewise. * include/Makefile.am: Adjust. * include/Makefile.in: Regenerate. From-SVN: r125244
2007-06-01 01:37:56 +02:00
struct __promote_2
{
typedef __typeof__(_Tp2() + _Up2()) __type;
re PR libstdc++/31426 (TR1 includes do not work with -std=c++0x) 2007-05-31 Paolo Carlini <pcarlini@suse.de> PR libstdc++/31426 * include/bits/c++config: Remove namespace association bits from tr1 to std. * include/ext/type_traits.h (__promote, __promote2, __promote3, __promote4): Add. * include/bits/hashtable.h: New. * include/bits/functional_hash.h: Likewise. * include/tr1/hashtable.h: Likewise. * include/tr1_impl/random: New. * include/tr1_impl/cinttypes: Likewise. * include/tr1_impl/cstdlib: Likewise. * include/tr1_impl/unordered_map: Likewise. * include/tr1_impl/cstdio: Likewise. * include/tr1_impl/boost_shared_ptr.h: Likewise. * include/tr1_impl/cctype: Likewise. * include/tr1_impl/random.tcc: Likewise. * include/tr1_impl/tuple: Likewise. * include/tr1_impl/functional_hash.h: Likewise. * include/tr1_impl/hashtable: Likewise. * include/tr1_impl/cmath: Likewise. * include/tr1_impl/type_traitsfwd.h: Likewise. * include/tr1_impl/hashtable_policy.h: Likewise. * include/tr1_impl/cfenv: Likewise. * include/tr1_impl/unordered_set: Likewise. * include/tr1_impl/functional: Likewise. * include/tr1_impl/utility: Likewise. * include/tr1_impl/complex: Likewise. * include/tr1_impl/type_traits: Likewise. * include/tr1_impl/cwchar: Likewise. * include/tr1_impl/cstdint: Likewise. * include/tr1_impl/regex: Likewise. * include/tr1_impl/array: Likewise. * include/tr1_impl/cwctype: Likewise. * include/tr1/type_traitsfwd.h: Remove. * include/tr1/boost_shared_ptr.h: Likewise. * include/tr1/common.h: Likewise. * include/tr1/hashtable: Likewise. * include/tr1/hashtable_policy.h: Likewise. * include/tr1/random.tcc: Likewise. * include/c_global/cinttypes: Include tr1_impl/cinttypes. * include/c_global/cstdlib: Likewise for cstdlib. * include/c_global/cstdio: Likewise for cstdio. * include/c_global/cctype: Likewise for cctype. * include/c_global/cmath: Likewise for cmath. * include/c_global/cfenv: Likewise for cfenv. * include/c_global/cwchar: Likewise for cwchar. * include/c_global/cstdint: Likewise for cstdint. * include/c_global/cwctype: Likewise for cwctype. * include/tr1/cinttypes: Likewise for cinttypes. * include/tr1/cstdlib: Likewise for cstdlib. * include/tr1/cstdio: Likewise for cstdio. * include/tr1/cctype: Likewise for cctype. * include/tr1/cmath: Likewise for cmath. * include/tr1/cfenv: Likewise for cfenv. * include/tr1/cwchar: Likewise for cwchar. * include/tr1/cstdint: Likewise for cstdint. * include/tr1/cwctype: Likewise for cwctype. * include/tr1/functional_hash.h: Likewise for functional_hash. * include/std/tuple: Include tr1_impl/tuple. * include/std/utility: Likewise for utility. * include/std/type_traits: Likewise for type_traits. (is_pod): Just forward to __is_pod. (has_trivial_default_constructor): Just forward to __has_trivial_constructor. (has_trivial_copy_constructor): Just forward to __has_trivial_copy. (has_trivial_assign): Just forward to __has_trivial_assign. (has_trivial_destructor): Just forward to __has_trivial_destructor. (has_nothrow_default_constructor): Just forward to __has_nothrow_constructor. (has_nothrow_copy_constructor): Just forward to __has_nothrow_copy. (has_nothrow_assign): Just forward to __has_nothrow_assign. (is_base_of): Just forward to __is_base_of. (is_signed, is_unsigned): Implement according to the C++0x specifications. * include/std/memory: Likewise for memory. * include/std/regex: Likewise for regex. * include/std/random: Likewise for random. * include/std/unordered_map: Likewise for unordered_map. * include/std/unordered_set: Likewise for unordered_set. * include/std/functional: Likewise for functional. * include/std/complex: Likewise for complex. * include/std/array: Likewise for array. * include/tr1/tuple: Likewise for tuple. * include/tr1/utility: Likewise for utility. * include/tr1/type_traits: Likewise for type_traits * include/tr1/memory: Likewise for memory. * include/tr1/regex: Likewise for regex. * include/tr1/random: Likewise for random. * include/tr1/unordered_map: Likewise for unordered_map. * include/tr1/unordered_set: Likewise for unordered_set. * include/tr1/functional: Likewise for functional. * include/tr1/complex: Likewise for complex. * include/tr1/array: Likewise for array. * include/c_global/ctgmath: Tweak. * include/c_global/cstdarg: Likewise. * include/c_global/ctime: Likewise. * include/c_global/climits: Likewise. * include/c_global/cfloat: Likewise. * include/c_global/ccomplex: Likewise. * include/c_global/cstdbool: Likewise. * include/tr1/poly_laguerre.tcc: Tweak, don't use _GLIBCXX_TR1. * include/tr1/riemann_zeta.tcc: Likewise. * include/tr1/beta_function.tcc: Likewise. * include/tr1/exp_integral.tcc: Likewise. * include/tr1/hypergeometric.tcc: Likewise. * include/tr1/modified_bessel_func.tcc: Likewise. * include/tr1/legendre_function.tcc: Likewise. * include/tr1/special_function_util.h: Likewise. * include/tr1/bessel_function.tcc: Likewise. * include/tr1/poly_hermite.tcc: Likewise. * include/tr1/ell_integral.tcc: Likewise. * include/tr1/gamma.tcc: Likewise. * include/tr1/stdlib.h: Likewise. * include/tr1/math.h: Likewise. * include/tr1/complex.h: Minor tweaks. * include/tr1/wctype.h: Likewise. * include/tr1/wchar.h: Likewise. * include/tr1/inttypes.h: Likewise. * include/tr1/tgmath.h: Likewise. * include/tr1/cstdbool: Likewise. * include/tr1/cfloat: Likewise. * include/tr1/ccomplex: Likewise. * include/tr1/ctime: Likewise. * include/tr1/climits: Likewise. * include/tr1/ctgmath: Likewise. * include/tr1/cstdarg: Likewise. * testsuite/tr1/headers.cc: Move... * testsuite/tr1/headers/all.cc: ... here. * testsuite/tr1/using_namespace_std_tr1.cc: Move... * testsuite/tr1/headers/c++200x/using_namespace_std_tr1.cc: ... here. * testsuite/tr1/headers/using_namespace_std_tr1.cc ... here. * testsuite/tr1/headers/c++200x/using_namespace_std_tr1.cc: New. * testsuite/20_util/tuple/requirements/explicit_instantiation.cc: Adjust namespace. * testsuite/20_util/has_nothrow_copy_constructor/value.cc: Adjust to the C++0x requirements. * testsuite/20_util/has_nothrow_default_constructor/value.cc: Likewise. * testsuite/20_util/has_trivial_copy_constructor/value.cc: Likewise. * testsuite/20_util/has_trivial_default_constructor/value.cc: Likewise. * testsuite/20_util/make_signed/requirements/typedefs_neg.cc: Adjust dg-error lines. * testsuite/20_util/make_unsigned/requirements/typedefs_neg.cc: Likewise. * testsuite/20_util/headers/type_traits/types_std_c++0x_neg.cc: Un-xfail. * testsuite/20_util/is_signed/value.cc: New. * testsuite/20_util/is_signed/requirements/typedefs.cc: Likewise. * testsuite/20_util/is_signed/requirements/explicit_instantiation.cc: Likewise. * testsuite/20_util/is_unsigned/value.cc: Likewise.. * testsuite/20_util/is_unsigned/requirements/typedefs.cc: Likewise. * testsuite/20_util/is_unsigned/requirements/explicit_instantiation.cc: Likewise. * include/Makefile.am: Adjust. * include/Makefile.in: Regenerate. From-SVN: r125244
2007-06-01 01:37:56 +02:00
};
template<typename _Tp, typename _Up, typename _Vp,
typename _Tp2 = typename __promote<_Tp>::__type,
typename _Up2 = typename __promote<_Up>::__type,
typename _Vp2 = typename __promote<_Vp>::__type>
re PR libstdc++/31426 (TR1 includes do not work with -std=c++0x) 2007-05-31 Paolo Carlini <pcarlini@suse.de> PR libstdc++/31426 * include/bits/c++config: Remove namespace association bits from tr1 to std. * include/ext/type_traits.h (__promote, __promote2, __promote3, __promote4): Add. * include/bits/hashtable.h: New. * include/bits/functional_hash.h: Likewise. * include/tr1/hashtable.h: Likewise. * include/tr1_impl/random: New. * include/tr1_impl/cinttypes: Likewise. * include/tr1_impl/cstdlib: Likewise. * include/tr1_impl/unordered_map: Likewise. * include/tr1_impl/cstdio: Likewise. * include/tr1_impl/boost_shared_ptr.h: Likewise. * include/tr1_impl/cctype: Likewise. * include/tr1_impl/random.tcc: Likewise. * include/tr1_impl/tuple: Likewise. * include/tr1_impl/functional_hash.h: Likewise. * include/tr1_impl/hashtable: Likewise. * include/tr1_impl/cmath: Likewise. * include/tr1_impl/type_traitsfwd.h: Likewise. * include/tr1_impl/hashtable_policy.h: Likewise. * include/tr1_impl/cfenv: Likewise. * include/tr1_impl/unordered_set: Likewise. * include/tr1_impl/functional: Likewise. * include/tr1_impl/utility: Likewise. * include/tr1_impl/complex: Likewise. * include/tr1_impl/type_traits: Likewise. * include/tr1_impl/cwchar: Likewise. * include/tr1_impl/cstdint: Likewise. * include/tr1_impl/regex: Likewise. * include/tr1_impl/array: Likewise. * include/tr1_impl/cwctype: Likewise. * include/tr1/type_traitsfwd.h: Remove. * include/tr1/boost_shared_ptr.h: Likewise. * include/tr1/common.h: Likewise. * include/tr1/hashtable: Likewise. * include/tr1/hashtable_policy.h: Likewise. * include/tr1/random.tcc: Likewise. * include/c_global/cinttypes: Include tr1_impl/cinttypes. * include/c_global/cstdlib: Likewise for cstdlib. * include/c_global/cstdio: Likewise for cstdio. * include/c_global/cctype: Likewise for cctype. * include/c_global/cmath: Likewise for cmath. * include/c_global/cfenv: Likewise for cfenv. * include/c_global/cwchar: Likewise for cwchar. * include/c_global/cstdint: Likewise for cstdint. * include/c_global/cwctype: Likewise for cwctype. * include/tr1/cinttypes: Likewise for cinttypes. * include/tr1/cstdlib: Likewise for cstdlib. * include/tr1/cstdio: Likewise for cstdio. * include/tr1/cctype: Likewise for cctype. * include/tr1/cmath: Likewise for cmath. * include/tr1/cfenv: Likewise for cfenv. * include/tr1/cwchar: Likewise for cwchar. * include/tr1/cstdint: Likewise for cstdint. * include/tr1/cwctype: Likewise for cwctype. * include/tr1/functional_hash.h: Likewise for functional_hash. * include/std/tuple: Include tr1_impl/tuple. * include/std/utility: Likewise for utility. * include/std/type_traits: Likewise for type_traits. (is_pod): Just forward to __is_pod. (has_trivial_default_constructor): Just forward to __has_trivial_constructor. (has_trivial_copy_constructor): Just forward to __has_trivial_copy. (has_trivial_assign): Just forward to __has_trivial_assign. (has_trivial_destructor): Just forward to __has_trivial_destructor. (has_nothrow_default_constructor): Just forward to __has_nothrow_constructor. (has_nothrow_copy_constructor): Just forward to __has_nothrow_copy. (has_nothrow_assign): Just forward to __has_nothrow_assign. (is_base_of): Just forward to __is_base_of. (is_signed, is_unsigned): Implement according to the C++0x specifications. * include/std/memory: Likewise for memory. * include/std/regex: Likewise for regex. * include/std/random: Likewise for random. * include/std/unordered_map: Likewise for unordered_map. * include/std/unordered_set: Likewise for unordered_set. * include/std/functional: Likewise for functional. * include/std/complex: Likewise for complex. * include/std/array: Likewise for array. * include/tr1/tuple: Likewise for tuple. * include/tr1/utility: Likewise for utility. * include/tr1/type_traits: Likewise for type_traits * include/tr1/memory: Likewise for memory. * include/tr1/regex: Likewise for regex. * include/tr1/random: Likewise for random. * include/tr1/unordered_map: Likewise for unordered_map. * include/tr1/unordered_set: Likewise for unordered_set. * include/tr1/functional: Likewise for functional. * include/tr1/complex: Likewise for complex. * include/tr1/array: Likewise for array. * include/c_global/ctgmath: Tweak. * include/c_global/cstdarg: Likewise. * include/c_global/ctime: Likewise. * include/c_global/climits: Likewise. * include/c_global/cfloat: Likewise. * include/c_global/ccomplex: Likewise. * include/c_global/cstdbool: Likewise. * include/tr1/poly_laguerre.tcc: Tweak, don't use _GLIBCXX_TR1. * include/tr1/riemann_zeta.tcc: Likewise. * include/tr1/beta_function.tcc: Likewise. * include/tr1/exp_integral.tcc: Likewise. * include/tr1/hypergeometric.tcc: Likewise. * include/tr1/modified_bessel_func.tcc: Likewise. * include/tr1/legendre_function.tcc: Likewise. * include/tr1/special_function_util.h: Likewise. * include/tr1/bessel_function.tcc: Likewise. * include/tr1/poly_hermite.tcc: Likewise. * include/tr1/ell_integral.tcc: Likewise. * include/tr1/gamma.tcc: Likewise. * include/tr1/stdlib.h: Likewise. * include/tr1/math.h: Likewise. * include/tr1/complex.h: Minor tweaks. * include/tr1/wctype.h: Likewise. * include/tr1/wchar.h: Likewise. * include/tr1/inttypes.h: Likewise. * include/tr1/tgmath.h: Likewise. * include/tr1/cstdbool: Likewise. * include/tr1/cfloat: Likewise. * include/tr1/ccomplex: Likewise. * include/tr1/ctime: Likewise. * include/tr1/climits: Likewise. * include/tr1/ctgmath: Likewise. * include/tr1/cstdarg: Likewise. * testsuite/tr1/headers.cc: Move... * testsuite/tr1/headers/all.cc: ... here. * testsuite/tr1/using_namespace_std_tr1.cc: Move... * testsuite/tr1/headers/c++200x/using_namespace_std_tr1.cc: ... here. * testsuite/tr1/headers/using_namespace_std_tr1.cc ... here. * testsuite/tr1/headers/c++200x/using_namespace_std_tr1.cc: New. * testsuite/20_util/tuple/requirements/explicit_instantiation.cc: Adjust namespace. * testsuite/20_util/has_nothrow_copy_constructor/value.cc: Adjust to the C++0x requirements. * testsuite/20_util/has_nothrow_default_constructor/value.cc: Likewise. * testsuite/20_util/has_trivial_copy_constructor/value.cc: Likewise. * testsuite/20_util/has_trivial_default_constructor/value.cc: Likewise. * testsuite/20_util/make_signed/requirements/typedefs_neg.cc: Adjust dg-error lines. * testsuite/20_util/make_unsigned/requirements/typedefs_neg.cc: Likewise. * testsuite/20_util/headers/type_traits/types_std_c++0x_neg.cc: Un-xfail. * testsuite/20_util/is_signed/value.cc: New. * testsuite/20_util/is_signed/requirements/typedefs.cc: Likewise. * testsuite/20_util/is_signed/requirements/explicit_instantiation.cc: Likewise. * testsuite/20_util/is_unsigned/value.cc: Likewise.. * testsuite/20_util/is_unsigned/requirements/typedefs.cc: Likewise. * testsuite/20_util/is_unsigned/requirements/explicit_instantiation.cc: Likewise. * include/Makefile.am: Adjust. * include/Makefile.in: Regenerate. From-SVN: r125244
2007-06-01 01:37:56 +02:00
struct __promote_3
{
typedef __typeof__(_Tp2() + _Up2() + _Vp2()) __type;
re PR libstdc++/31426 (TR1 includes do not work with -std=c++0x) 2007-05-31 Paolo Carlini <pcarlini@suse.de> PR libstdc++/31426 * include/bits/c++config: Remove namespace association bits from tr1 to std. * include/ext/type_traits.h (__promote, __promote2, __promote3, __promote4): Add. * include/bits/hashtable.h: New. * include/bits/functional_hash.h: Likewise. * include/tr1/hashtable.h: Likewise. * include/tr1_impl/random: New. * include/tr1_impl/cinttypes: Likewise. * include/tr1_impl/cstdlib: Likewise. * include/tr1_impl/unordered_map: Likewise. * include/tr1_impl/cstdio: Likewise. * include/tr1_impl/boost_shared_ptr.h: Likewise. * include/tr1_impl/cctype: Likewise. * include/tr1_impl/random.tcc: Likewise. * include/tr1_impl/tuple: Likewise. * include/tr1_impl/functional_hash.h: Likewise. * include/tr1_impl/hashtable: Likewise. * include/tr1_impl/cmath: Likewise. * include/tr1_impl/type_traitsfwd.h: Likewise. * include/tr1_impl/hashtable_policy.h: Likewise. * include/tr1_impl/cfenv: Likewise. * include/tr1_impl/unordered_set: Likewise. * include/tr1_impl/functional: Likewise. * include/tr1_impl/utility: Likewise. * include/tr1_impl/complex: Likewise. * include/tr1_impl/type_traits: Likewise. * include/tr1_impl/cwchar: Likewise. * include/tr1_impl/cstdint: Likewise. * include/tr1_impl/regex: Likewise. * include/tr1_impl/array: Likewise. * include/tr1_impl/cwctype: Likewise. * include/tr1/type_traitsfwd.h: Remove. * include/tr1/boost_shared_ptr.h: Likewise. * include/tr1/common.h: Likewise. * include/tr1/hashtable: Likewise. * include/tr1/hashtable_policy.h: Likewise. * include/tr1/random.tcc: Likewise. * include/c_global/cinttypes: Include tr1_impl/cinttypes. * include/c_global/cstdlib: Likewise for cstdlib. * include/c_global/cstdio: Likewise for cstdio. * include/c_global/cctype: Likewise for cctype. * include/c_global/cmath: Likewise for cmath. * include/c_global/cfenv: Likewise for cfenv. * include/c_global/cwchar: Likewise for cwchar. * include/c_global/cstdint: Likewise for cstdint. * include/c_global/cwctype: Likewise for cwctype. * include/tr1/cinttypes: Likewise for cinttypes. * include/tr1/cstdlib: Likewise for cstdlib. * include/tr1/cstdio: Likewise for cstdio. * include/tr1/cctype: Likewise for cctype. * include/tr1/cmath: Likewise for cmath. * include/tr1/cfenv: Likewise for cfenv. * include/tr1/cwchar: Likewise for cwchar. * include/tr1/cstdint: Likewise for cstdint. * include/tr1/cwctype: Likewise for cwctype. * include/tr1/functional_hash.h: Likewise for functional_hash. * include/std/tuple: Include tr1_impl/tuple. * include/std/utility: Likewise for utility. * include/std/type_traits: Likewise for type_traits. (is_pod): Just forward to __is_pod. (has_trivial_default_constructor): Just forward to __has_trivial_constructor. (has_trivial_copy_constructor): Just forward to __has_trivial_copy. (has_trivial_assign): Just forward to __has_trivial_assign. (has_trivial_destructor): Just forward to __has_trivial_destructor. (has_nothrow_default_constructor): Just forward to __has_nothrow_constructor. (has_nothrow_copy_constructor): Just forward to __has_nothrow_copy. (has_nothrow_assign): Just forward to __has_nothrow_assign. (is_base_of): Just forward to __is_base_of. (is_signed, is_unsigned): Implement according to the C++0x specifications. * include/std/memory: Likewise for memory. * include/std/regex: Likewise for regex. * include/std/random: Likewise for random. * include/std/unordered_map: Likewise for unordered_map. * include/std/unordered_set: Likewise for unordered_set. * include/std/functional: Likewise for functional. * include/std/complex: Likewise for complex. * include/std/array: Likewise for array. * include/tr1/tuple: Likewise for tuple. * include/tr1/utility: Likewise for utility. * include/tr1/type_traits: Likewise for type_traits * include/tr1/memory: Likewise for memory. * include/tr1/regex: Likewise for regex. * include/tr1/random: Likewise for random. * include/tr1/unordered_map: Likewise for unordered_map. * include/tr1/unordered_set: Likewise for unordered_set. * include/tr1/functional: Likewise for functional. * include/tr1/complex: Likewise for complex. * include/tr1/array: Likewise for array. * include/c_global/ctgmath: Tweak. * include/c_global/cstdarg: Likewise. * include/c_global/ctime: Likewise. * include/c_global/climits: Likewise. * include/c_global/cfloat: Likewise. * include/c_global/ccomplex: Likewise. * include/c_global/cstdbool: Likewise. * include/tr1/poly_laguerre.tcc: Tweak, don't use _GLIBCXX_TR1. * include/tr1/riemann_zeta.tcc: Likewise. * include/tr1/beta_function.tcc: Likewise. * include/tr1/exp_integral.tcc: Likewise. * include/tr1/hypergeometric.tcc: Likewise. * include/tr1/modified_bessel_func.tcc: Likewise. * include/tr1/legendre_function.tcc: Likewise. * include/tr1/special_function_util.h: Likewise. * include/tr1/bessel_function.tcc: Likewise. * include/tr1/poly_hermite.tcc: Likewise. * include/tr1/ell_integral.tcc: Likewise. * include/tr1/gamma.tcc: Likewise. * include/tr1/stdlib.h: Likewise. * include/tr1/math.h: Likewise. * include/tr1/complex.h: Minor tweaks. * include/tr1/wctype.h: Likewise. * include/tr1/wchar.h: Likewise. * include/tr1/inttypes.h: Likewise. * include/tr1/tgmath.h: Likewise. * include/tr1/cstdbool: Likewise. * include/tr1/cfloat: Likewise. * include/tr1/ccomplex: Likewise. * include/tr1/ctime: Likewise. * include/tr1/climits: Likewise. * include/tr1/ctgmath: Likewise. * include/tr1/cstdarg: Likewise. * testsuite/tr1/headers.cc: Move... * testsuite/tr1/headers/all.cc: ... here. * testsuite/tr1/using_namespace_std_tr1.cc: Move... * testsuite/tr1/headers/c++200x/using_namespace_std_tr1.cc: ... here. * testsuite/tr1/headers/using_namespace_std_tr1.cc ... here. * testsuite/tr1/headers/c++200x/using_namespace_std_tr1.cc: New. * testsuite/20_util/tuple/requirements/explicit_instantiation.cc: Adjust namespace. * testsuite/20_util/has_nothrow_copy_constructor/value.cc: Adjust to the C++0x requirements. * testsuite/20_util/has_nothrow_default_constructor/value.cc: Likewise. * testsuite/20_util/has_trivial_copy_constructor/value.cc: Likewise. * testsuite/20_util/has_trivial_default_constructor/value.cc: Likewise. * testsuite/20_util/make_signed/requirements/typedefs_neg.cc: Adjust dg-error lines. * testsuite/20_util/make_unsigned/requirements/typedefs_neg.cc: Likewise. * testsuite/20_util/headers/type_traits/types_std_c++0x_neg.cc: Un-xfail. * testsuite/20_util/is_signed/value.cc: New. * testsuite/20_util/is_signed/requirements/typedefs.cc: Likewise. * testsuite/20_util/is_signed/requirements/explicit_instantiation.cc: Likewise. * testsuite/20_util/is_unsigned/value.cc: Likewise.. * testsuite/20_util/is_unsigned/requirements/typedefs.cc: Likewise. * testsuite/20_util/is_unsigned/requirements/explicit_instantiation.cc: Likewise. * include/Makefile.am: Adjust. * include/Makefile.in: Regenerate. From-SVN: r125244
2007-06-01 01:37:56 +02:00
};
template<typename _Tp, typename _Up, typename _Vp, typename _Wp,
typename _Tp2 = typename __promote<_Tp>::__type,
typename _Up2 = typename __promote<_Up>::__type,
typename _Vp2 = typename __promote<_Vp>::__type,
typename _Wp2 = typename __promote<_Wp>::__type>
re PR libstdc++/31426 (TR1 includes do not work with -std=c++0x) 2007-05-31 Paolo Carlini <pcarlini@suse.de> PR libstdc++/31426 * include/bits/c++config: Remove namespace association bits from tr1 to std. * include/ext/type_traits.h (__promote, __promote2, __promote3, __promote4): Add. * include/bits/hashtable.h: New. * include/bits/functional_hash.h: Likewise. * include/tr1/hashtable.h: Likewise. * include/tr1_impl/random: New. * include/tr1_impl/cinttypes: Likewise. * include/tr1_impl/cstdlib: Likewise. * include/tr1_impl/unordered_map: Likewise. * include/tr1_impl/cstdio: Likewise. * include/tr1_impl/boost_shared_ptr.h: Likewise. * include/tr1_impl/cctype: Likewise. * include/tr1_impl/random.tcc: Likewise. * include/tr1_impl/tuple: Likewise. * include/tr1_impl/functional_hash.h: Likewise. * include/tr1_impl/hashtable: Likewise. * include/tr1_impl/cmath: Likewise. * include/tr1_impl/type_traitsfwd.h: Likewise. * include/tr1_impl/hashtable_policy.h: Likewise. * include/tr1_impl/cfenv: Likewise. * include/tr1_impl/unordered_set: Likewise. * include/tr1_impl/functional: Likewise. * include/tr1_impl/utility: Likewise. * include/tr1_impl/complex: Likewise. * include/tr1_impl/type_traits: Likewise. * include/tr1_impl/cwchar: Likewise. * include/tr1_impl/cstdint: Likewise. * include/tr1_impl/regex: Likewise. * include/tr1_impl/array: Likewise. * include/tr1_impl/cwctype: Likewise. * include/tr1/type_traitsfwd.h: Remove. * include/tr1/boost_shared_ptr.h: Likewise. * include/tr1/common.h: Likewise. * include/tr1/hashtable: Likewise. * include/tr1/hashtable_policy.h: Likewise. * include/tr1/random.tcc: Likewise. * include/c_global/cinttypes: Include tr1_impl/cinttypes. * include/c_global/cstdlib: Likewise for cstdlib. * include/c_global/cstdio: Likewise for cstdio. * include/c_global/cctype: Likewise for cctype. * include/c_global/cmath: Likewise for cmath. * include/c_global/cfenv: Likewise for cfenv. * include/c_global/cwchar: Likewise for cwchar. * include/c_global/cstdint: Likewise for cstdint. * include/c_global/cwctype: Likewise for cwctype. * include/tr1/cinttypes: Likewise for cinttypes. * include/tr1/cstdlib: Likewise for cstdlib. * include/tr1/cstdio: Likewise for cstdio. * include/tr1/cctype: Likewise for cctype. * include/tr1/cmath: Likewise for cmath. * include/tr1/cfenv: Likewise for cfenv. * include/tr1/cwchar: Likewise for cwchar. * include/tr1/cstdint: Likewise for cstdint. * include/tr1/cwctype: Likewise for cwctype. * include/tr1/functional_hash.h: Likewise for functional_hash. * include/std/tuple: Include tr1_impl/tuple. * include/std/utility: Likewise for utility. * include/std/type_traits: Likewise for type_traits. (is_pod): Just forward to __is_pod. (has_trivial_default_constructor): Just forward to __has_trivial_constructor. (has_trivial_copy_constructor): Just forward to __has_trivial_copy. (has_trivial_assign): Just forward to __has_trivial_assign. (has_trivial_destructor): Just forward to __has_trivial_destructor. (has_nothrow_default_constructor): Just forward to __has_nothrow_constructor. (has_nothrow_copy_constructor): Just forward to __has_nothrow_copy. (has_nothrow_assign): Just forward to __has_nothrow_assign. (is_base_of): Just forward to __is_base_of. (is_signed, is_unsigned): Implement according to the C++0x specifications. * include/std/memory: Likewise for memory. * include/std/regex: Likewise for regex. * include/std/random: Likewise for random. * include/std/unordered_map: Likewise for unordered_map. * include/std/unordered_set: Likewise for unordered_set. * include/std/functional: Likewise for functional. * include/std/complex: Likewise for complex. * include/std/array: Likewise for array. * include/tr1/tuple: Likewise for tuple. * include/tr1/utility: Likewise for utility. * include/tr1/type_traits: Likewise for type_traits * include/tr1/memory: Likewise for memory. * include/tr1/regex: Likewise for regex. * include/tr1/random: Likewise for random. * include/tr1/unordered_map: Likewise for unordered_map. * include/tr1/unordered_set: Likewise for unordered_set. * include/tr1/functional: Likewise for functional. * include/tr1/complex: Likewise for complex. * include/tr1/array: Likewise for array. * include/c_global/ctgmath: Tweak. * include/c_global/cstdarg: Likewise. * include/c_global/ctime: Likewise. * include/c_global/climits: Likewise. * include/c_global/cfloat: Likewise. * include/c_global/ccomplex: Likewise. * include/c_global/cstdbool: Likewise. * include/tr1/poly_laguerre.tcc: Tweak, don't use _GLIBCXX_TR1. * include/tr1/riemann_zeta.tcc: Likewise. * include/tr1/beta_function.tcc: Likewise. * include/tr1/exp_integral.tcc: Likewise. * include/tr1/hypergeometric.tcc: Likewise. * include/tr1/modified_bessel_func.tcc: Likewise. * include/tr1/legendre_function.tcc: Likewise. * include/tr1/special_function_util.h: Likewise. * include/tr1/bessel_function.tcc: Likewise. * include/tr1/poly_hermite.tcc: Likewise. * include/tr1/ell_integral.tcc: Likewise. * include/tr1/gamma.tcc: Likewise. * include/tr1/stdlib.h: Likewise. * include/tr1/math.h: Likewise. * include/tr1/complex.h: Minor tweaks. * include/tr1/wctype.h: Likewise. * include/tr1/wchar.h: Likewise. * include/tr1/inttypes.h: Likewise. * include/tr1/tgmath.h: Likewise. * include/tr1/cstdbool: Likewise. * include/tr1/cfloat: Likewise. * include/tr1/ccomplex: Likewise. * include/tr1/ctime: Likewise. * include/tr1/climits: Likewise. * include/tr1/ctgmath: Likewise. * include/tr1/cstdarg: Likewise. * testsuite/tr1/headers.cc: Move... * testsuite/tr1/headers/all.cc: ... here. * testsuite/tr1/using_namespace_std_tr1.cc: Move... * testsuite/tr1/headers/c++200x/using_namespace_std_tr1.cc: ... here. * testsuite/tr1/headers/using_namespace_std_tr1.cc ... here. * testsuite/tr1/headers/c++200x/using_namespace_std_tr1.cc: New. * testsuite/20_util/tuple/requirements/explicit_instantiation.cc: Adjust namespace. * testsuite/20_util/has_nothrow_copy_constructor/value.cc: Adjust to the C++0x requirements. * testsuite/20_util/has_nothrow_default_constructor/value.cc: Likewise. * testsuite/20_util/has_trivial_copy_constructor/value.cc: Likewise. * testsuite/20_util/has_trivial_default_constructor/value.cc: Likewise. * testsuite/20_util/make_signed/requirements/typedefs_neg.cc: Adjust dg-error lines. * testsuite/20_util/make_unsigned/requirements/typedefs_neg.cc: Likewise. * testsuite/20_util/headers/type_traits/types_std_c++0x_neg.cc: Un-xfail. * testsuite/20_util/is_signed/value.cc: New. * testsuite/20_util/is_signed/requirements/typedefs.cc: Likewise. * testsuite/20_util/is_signed/requirements/explicit_instantiation.cc: Likewise. * testsuite/20_util/is_unsigned/value.cc: Likewise.. * testsuite/20_util/is_unsigned/requirements/typedefs.cc: Likewise. * testsuite/20_util/is_unsigned/requirements/explicit_instantiation.cc: Likewise. * include/Makefile.am: Adjust. * include/Makefile.in: Regenerate. From-SVN: r125244
2007-06-01 01:37:56 +02:00
struct __promote_4
{
typedef __typeof__(_Tp2() + _Up2() + _Vp2() + _Wp2()) __type;
re PR libstdc++/31426 (TR1 includes do not work with -std=c++0x) 2007-05-31 Paolo Carlini <pcarlini@suse.de> PR libstdc++/31426 * include/bits/c++config: Remove namespace association bits from tr1 to std. * include/ext/type_traits.h (__promote, __promote2, __promote3, __promote4): Add. * include/bits/hashtable.h: New. * include/bits/functional_hash.h: Likewise. * include/tr1/hashtable.h: Likewise. * include/tr1_impl/random: New. * include/tr1_impl/cinttypes: Likewise. * include/tr1_impl/cstdlib: Likewise. * include/tr1_impl/unordered_map: Likewise. * include/tr1_impl/cstdio: Likewise. * include/tr1_impl/boost_shared_ptr.h: Likewise. * include/tr1_impl/cctype: Likewise. * include/tr1_impl/random.tcc: Likewise. * include/tr1_impl/tuple: Likewise. * include/tr1_impl/functional_hash.h: Likewise. * include/tr1_impl/hashtable: Likewise. * include/tr1_impl/cmath: Likewise. * include/tr1_impl/type_traitsfwd.h: Likewise. * include/tr1_impl/hashtable_policy.h: Likewise. * include/tr1_impl/cfenv: Likewise. * include/tr1_impl/unordered_set: Likewise. * include/tr1_impl/functional: Likewise. * include/tr1_impl/utility: Likewise. * include/tr1_impl/complex: Likewise. * include/tr1_impl/type_traits: Likewise. * include/tr1_impl/cwchar: Likewise. * include/tr1_impl/cstdint: Likewise. * include/tr1_impl/regex: Likewise. * include/tr1_impl/array: Likewise. * include/tr1_impl/cwctype: Likewise. * include/tr1/type_traitsfwd.h: Remove. * include/tr1/boost_shared_ptr.h: Likewise. * include/tr1/common.h: Likewise. * include/tr1/hashtable: Likewise. * include/tr1/hashtable_policy.h: Likewise. * include/tr1/random.tcc: Likewise. * include/c_global/cinttypes: Include tr1_impl/cinttypes. * include/c_global/cstdlib: Likewise for cstdlib. * include/c_global/cstdio: Likewise for cstdio. * include/c_global/cctype: Likewise for cctype. * include/c_global/cmath: Likewise for cmath. * include/c_global/cfenv: Likewise for cfenv. * include/c_global/cwchar: Likewise for cwchar. * include/c_global/cstdint: Likewise for cstdint. * include/c_global/cwctype: Likewise for cwctype. * include/tr1/cinttypes: Likewise for cinttypes. * include/tr1/cstdlib: Likewise for cstdlib. * include/tr1/cstdio: Likewise for cstdio. * include/tr1/cctype: Likewise for cctype. * include/tr1/cmath: Likewise for cmath. * include/tr1/cfenv: Likewise for cfenv. * include/tr1/cwchar: Likewise for cwchar. * include/tr1/cstdint: Likewise for cstdint. * include/tr1/cwctype: Likewise for cwctype. * include/tr1/functional_hash.h: Likewise for functional_hash. * include/std/tuple: Include tr1_impl/tuple. * include/std/utility: Likewise for utility. * include/std/type_traits: Likewise for type_traits. (is_pod): Just forward to __is_pod. (has_trivial_default_constructor): Just forward to __has_trivial_constructor. (has_trivial_copy_constructor): Just forward to __has_trivial_copy. (has_trivial_assign): Just forward to __has_trivial_assign. (has_trivial_destructor): Just forward to __has_trivial_destructor. (has_nothrow_default_constructor): Just forward to __has_nothrow_constructor. (has_nothrow_copy_constructor): Just forward to __has_nothrow_copy. (has_nothrow_assign): Just forward to __has_nothrow_assign. (is_base_of): Just forward to __is_base_of. (is_signed, is_unsigned): Implement according to the C++0x specifications. * include/std/memory: Likewise for memory. * include/std/regex: Likewise for regex. * include/std/random: Likewise for random. * include/std/unordered_map: Likewise for unordered_map. * include/std/unordered_set: Likewise for unordered_set. * include/std/functional: Likewise for functional. * include/std/complex: Likewise for complex. * include/std/array: Likewise for array. * include/tr1/tuple: Likewise for tuple. * include/tr1/utility: Likewise for utility. * include/tr1/type_traits: Likewise for type_traits * include/tr1/memory: Likewise for memory. * include/tr1/regex: Likewise for regex. * include/tr1/random: Likewise for random. * include/tr1/unordered_map: Likewise for unordered_map. * include/tr1/unordered_set: Likewise for unordered_set. * include/tr1/functional: Likewise for functional. * include/tr1/complex: Likewise for complex. * include/tr1/array: Likewise for array. * include/c_global/ctgmath: Tweak. * include/c_global/cstdarg: Likewise. * include/c_global/ctime: Likewise. * include/c_global/climits: Likewise. * include/c_global/cfloat: Likewise. * include/c_global/ccomplex: Likewise. * include/c_global/cstdbool: Likewise. * include/tr1/poly_laguerre.tcc: Tweak, don't use _GLIBCXX_TR1. * include/tr1/riemann_zeta.tcc: Likewise. * include/tr1/beta_function.tcc: Likewise. * include/tr1/exp_integral.tcc: Likewise. * include/tr1/hypergeometric.tcc: Likewise. * include/tr1/modified_bessel_func.tcc: Likewise. * include/tr1/legendre_function.tcc: Likewise. * include/tr1/special_function_util.h: Likewise. * include/tr1/bessel_function.tcc: Likewise. * include/tr1/poly_hermite.tcc: Likewise. * include/tr1/ell_integral.tcc: Likewise. * include/tr1/gamma.tcc: Likewise. * include/tr1/stdlib.h: Likewise. * include/tr1/math.h: Likewise. * include/tr1/complex.h: Minor tweaks. * include/tr1/wctype.h: Likewise. * include/tr1/wchar.h: Likewise. * include/tr1/inttypes.h: Likewise. * include/tr1/tgmath.h: Likewise. * include/tr1/cstdbool: Likewise. * include/tr1/cfloat: Likewise. * include/tr1/ccomplex: Likewise. * include/tr1/ctime: Likewise. * include/tr1/climits: Likewise. * include/tr1/ctgmath: Likewise. * include/tr1/cstdarg: Likewise. * testsuite/tr1/headers.cc: Move... * testsuite/tr1/headers/all.cc: ... here. * testsuite/tr1/using_namespace_std_tr1.cc: Move... * testsuite/tr1/headers/c++200x/using_namespace_std_tr1.cc: ... here. * testsuite/tr1/headers/using_namespace_std_tr1.cc ... here. * testsuite/tr1/headers/c++200x/using_namespace_std_tr1.cc: New. * testsuite/20_util/tuple/requirements/explicit_instantiation.cc: Adjust namespace. * testsuite/20_util/has_nothrow_copy_constructor/value.cc: Adjust to the C++0x requirements. * testsuite/20_util/has_nothrow_default_constructor/value.cc: Likewise. * testsuite/20_util/has_trivial_copy_constructor/value.cc: Likewise. * testsuite/20_util/has_trivial_default_constructor/value.cc: Likewise. * testsuite/20_util/make_signed/requirements/typedefs_neg.cc: Adjust dg-error lines. * testsuite/20_util/make_unsigned/requirements/typedefs_neg.cc: Likewise. * testsuite/20_util/headers/type_traits/types_std_c++0x_neg.cc: Un-xfail. * testsuite/20_util/is_signed/value.cc: New. * testsuite/20_util/is_signed/requirements/typedefs.cc: Likewise. * testsuite/20_util/is_signed/requirements/explicit_instantiation.cc: Likewise. * testsuite/20_util/is_unsigned/value.cc: Likewise.. * testsuite/20_util/is_unsigned/requirements/typedefs.cc: Likewise. * testsuite/20_util/is_unsigned/requirements/explicit_instantiation.cc: Likewise. * include/Makefile.am: Adjust. * include/Makefile.in: Regenerate. From-SVN: r125244
2007-06-01 01:37:56 +02:00
};
#endif
re PR libstdc++/31426 (TR1 includes do not work with -std=c++0x) 2007-05-31 Paolo Carlini <pcarlini@suse.de> PR libstdc++/31426 * include/bits/c++config: Remove namespace association bits from tr1 to std. * include/ext/type_traits.h (__promote, __promote2, __promote3, __promote4): Add. * include/bits/hashtable.h: New. * include/bits/functional_hash.h: Likewise. * include/tr1/hashtable.h: Likewise. * include/tr1_impl/random: New. * include/tr1_impl/cinttypes: Likewise. * include/tr1_impl/cstdlib: Likewise. * include/tr1_impl/unordered_map: Likewise. * include/tr1_impl/cstdio: Likewise. * include/tr1_impl/boost_shared_ptr.h: Likewise. * include/tr1_impl/cctype: Likewise. * include/tr1_impl/random.tcc: Likewise. * include/tr1_impl/tuple: Likewise. * include/tr1_impl/functional_hash.h: Likewise. * include/tr1_impl/hashtable: Likewise. * include/tr1_impl/cmath: Likewise. * include/tr1_impl/type_traitsfwd.h: Likewise. * include/tr1_impl/hashtable_policy.h: Likewise. * include/tr1_impl/cfenv: Likewise. * include/tr1_impl/unordered_set: Likewise. * include/tr1_impl/functional: Likewise. * include/tr1_impl/utility: Likewise. * include/tr1_impl/complex: Likewise. * include/tr1_impl/type_traits: Likewise. * include/tr1_impl/cwchar: Likewise. * include/tr1_impl/cstdint: Likewise. * include/tr1_impl/regex: Likewise. * include/tr1_impl/array: Likewise. * include/tr1_impl/cwctype: Likewise. * include/tr1/type_traitsfwd.h: Remove. * include/tr1/boost_shared_ptr.h: Likewise. * include/tr1/common.h: Likewise. * include/tr1/hashtable: Likewise. * include/tr1/hashtable_policy.h: Likewise. * include/tr1/random.tcc: Likewise. * include/c_global/cinttypes: Include tr1_impl/cinttypes. * include/c_global/cstdlib: Likewise for cstdlib. * include/c_global/cstdio: Likewise for cstdio. * include/c_global/cctype: Likewise for cctype. * include/c_global/cmath: Likewise for cmath. * include/c_global/cfenv: Likewise for cfenv. * include/c_global/cwchar: Likewise for cwchar. * include/c_global/cstdint: Likewise for cstdint. * include/c_global/cwctype: Likewise for cwctype. * include/tr1/cinttypes: Likewise for cinttypes. * include/tr1/cstdlib: Likewise for cstdlib. * include/tr1/cstdio: Likewise for cstdio. * include/tr1/cctype: Likewise for cctype. * include/tr1/cmath: Likewise for cmath. * include/tr1/cfenv: Likewise for cfenv. * include/tr1/cwchar: Likewise for cwchar. * include/tr1/cstdint: Likewise for cstdint. * include/tr1/cwctype: Likewise for cwctype. * include/tr1/functional_hash.h: Likewise for functional_hash. * include/std/tuple: Include tr1_impl/tuple. * include/std/utility: Likewise for utility. * include/std/type_traits: Likewise for type_traits. (is_pod): Just forward to __is_pod. (has_trivial_default_constructor): Just forward to __has_trivial_constructor. (has_trivial_copy_constructor): Just forward to __has_trivial_copy. (has_trivial_assign): Just forward to __has_trivial_assign. (has_trivial_destructor): Just forward to __has_trivial_destructor. (has_nothrow_default_constructor): Just forward to __has_nothrow_constructor. (has_nothrow_copy_constructor): Just forward to __has_nothrow_copy. (has_nothrow_assign): Just forward to __has_nothrow_assign. (is_base_of): Just forward to __is_base_of. (is_signed, is_unsigned): Implement according to the C++0x specifications. * include/std/memory: Likewise for memory. * include/std/regex: Likewise for regex. * include/std/random: Likewise for random. * include/std/unordered_map: Likewise for unordered_map. * include/std/unordered_set: Likewise for unordered_set. * include/std/functional: Likewise for functional. * include/std/complex: Likewise for complex. * include/std/array: Likewise for array. * include/tr1/tuple: Likewise for tuple. * include/tr1/utility: Likewise for utility. * include/tr1/type_traits: Likewise for type_traits * include/tr1/memory: Likewise for memory. * include/tr1/regex: Likewise for regex. * include/tr1/random: Likewise for random. * include/tr1/unordered_map: Likewise for unordered_map. * include/tr1/unordered_set: Likewise for unordered_set. * include/tr1/functional: Likewise for functional. * include/tr1/complex: Likewise for complex. * include/tr1/array: Likewise for array. * include/c_global/ctgmath: Tweak. * include/c_global/cstdarg: Likewise. * include/c_global/ctime: Likewise. * include/c_global/climits: Likewise. * include/c_global/cfloat: Likewise. * include/c_global/ccomplex: Likewise. * include/c_global/cstdbool: Likewise. * include/tr1/poly_laguerre.tcc: Tweak, don't use _GLIBCXX_TR1. * include/tr1/riemann_zeta.tcc: Likewise. * include/tr1/beta_function.tcc: Likewise. * include/tr1/exp_integral.tcc: Likewise. * include/tr1/hypergeometric.tcc: Likewise. * include/tr1/modified_bessel_func.tcc: Likewise. * include/tr1/legendre_function.tcc: Likewise. * include/tr1/special_function_util.h: Likewise. * include/tr1/bessel_function.tcc: Likewise. * include/tr1/poly_hermite.tcc: Likewise. * include/tr1/ell_integral.tcc: Likewise. * include/tr1/gamma.tcc: Likewise. * include/tr1/stdlib.h: Likewise. * include/tr1/math.h: Likewise. * include/tr1/complex.h: Minor tweaks. * include/tr1/wctype.h: Likewise. * include/tr1/wchar.h: Likewise. * include/tr1/inttypes.h: Likewise. * include/tr1/tgmath.h: Likewise. * include/tr1/cstdbool: Likewise. * include/tr1/cfloat: Likewise. * include/tr1/ccomplex: Likewise. * include/tr1/ctime: Likewise. * include/tr1/climits: Likewise. * include/tr1/ctgmath: Likewise. * include/tr1/cstdarg: Likewise. * testsuite/tr1/headers.cc: Move... * testsuite/tr1/headers/all.cc: ... here. * testsuite/tr1/using_namespace_std_tr1.cc: Move... * testsuite/tr1/headers/c++200x/using_namespace_std_tr1.cc: ... here. * testsuite/tr1/headers/using_namespace_std_tr1.cc ... here. * testsuite/tr1/headers/c++200x/using_namespace_std_tr1.cc: New. * testsuite/20_util/tuple/requirements/explicit_instantiation.cc: Adjust namespace. * testsuite/20_util/has_nothrow_copy_constructor/value.cc: Adjust to the C++0x requirements. * testsuite/20_util/has_nothrow_default_constructor/value.cc: Likewise. * testsuite/20_util/has_trivial_copy_constructor/value.cc: Likewise. * testsuite/20_util/has_trivial_default_constructor/value.cc: Likewise. * testsuite/20_util/make_signed/requirements/typedefs_neg.cc: Adjust dg-error lines. * testsuite/20_util/make_unsigned/requirements/typedefs_neg.cc: Likewise. * testsuite/20_util/headers/type_traits/types_std_c++0x_neg.cc: Un-xfail. * testsuite/20_util/is_signed/value.cc: New. * testsuite/20_util/is_signed/requirements/typedefs.cc: Likewise. * testsuite/20_util/is_signed/requirements/explicit_instantiation.cc: Likewise. * testsuite/20_util/is_unsigned/value.cc: Likewise.. * testsuite/20_util/is_unsigned/requirements/typedefs.cc: Likewise. * testsuite/20_util/is_unsigned/requirements/explicit_instantiation.cc: Likewise. * include/Makefile.am: Adjust. * include/Makefile.in: Regenerate. From-SVN: r125244
2007-06-01 01:37:56 +02:00
PR libstdc++/36104 part four 2011-01-30 Benjamin Kosnik <bkoz@redhat.com> PR libstdc++/36104 part four * include/bits/c++config (_GLIBCXX_STD): Remove. (_GLIBCXX_STD_D, _GLIBCXX_PR): Now _GLIBCXX_STD_C. (_GLIBCXX_P): Now _GLIBCXX_STD_A. (_GLIBCXX_NAMESPACE_DEBUG, _GLIBCXX_NAMESPACE_PARALLEL, _GLIBCXX_NAMESPACE_PROFILE, _GLIBCXX_NAMESPACE_VERSION): Remove. (_GLIBCXX_INLINE_DEBUG, _GLIBCXX_INLINE_PARALLEL, _GLIBCXX_INLINE_PROFILE): Remove. (_GLIBCXX_BEGIN_NAMESPACE(X)): Remove. (_GLIBCXX_END_NAMESPACE): Remove. (_GLIBCXX_BEGIN_NESTED_NAMESPACE(X, Y)): Remove. (_GLIBCXX_END_NESTED_NAMESPACE): Remove. (_GLIBCXX_BEGIN_NAMESPACE_ALGO): Add. (_GLIBCXX_END_NAMESPACE_ALGO): Add. (_GLIBCXX_BEGIN_NAMESPACE_CONTAINER): Add. (_GLIBCXX_END_NAMESPACE_CONTAINER): Add. (_GLIBCXX_BEGIN_NAMESPACE_VERSION): Add. (_GLIBCXX_END_NAMESPACE_VERSION): Add. (_GLIBCXX_BEGIN_LDBL_NAMESPACE): To _GLIBCXX_BEGIN_NAMESPACE_LDBL. (_GLIBCXX_END_LDBL_NAMESPACE): To _GLIBCXX_END_NAMESPACE_LDBL. (_GLIBCXX_VISIBILITY_ATTR): Revert to _GLIBCXX_VISIBILITY. * include/*: Use new macros for namespace scope. * config/*: Same. * src/*: Same. * src/Makefile.am (sources): Remove debug_list.cc, add compatibility-debug_list-2.cc. (parallel_sources): Remove parallel_list.cc, add compatibility-parallel_list-2.cc. (compatibility-parallel_list-2.[o,lo]): New rule. * src/Makefile.in: Regenerate. * src/debug_list.cc: Remove. * src/parallel_list.cc: Remove. * src/compatibility-list-2.cc: New. * src/compatibility-debug_list-2.cc: New. * src/compatibility-parallel_list-2.cc: New. * doc/doxygen/user.cfg.in: Adjust macros. * testsuite/20_util/auto_ptr/assign_neg.cc: Adjust line numbers, macros. * testsuite/20_util/declval/requirements/1_neg.cc: Same. * testsuite/20_util/duration/requirements/typedefs_neg1.cc: Same. * testsuite/20_util/duration/requirements/typedefs_neg2.cc: Same. * testsuite/20_util/duration/requirements/typedefs_neg3.cc: Same. * testsuite/20_util/forward/c_neg.cc: Same. * testsuite/20_util/forward/f_neg.cc: Same. * testsuite/20_util/make_signed/requirements/typedefs_neg.cc: Same. * testsuite/20_util/make_unsigned/requirements/typedefs_neg.cc: Same. * testsuite/20_util/ratio/cons/cons_overflow_neg.cc: Same. * testsuite/20_util/ratio/operations/ops_overflow_neg.cc: Same. * testsuite/20_util/shared_ptr/cons/43820_neg.cc: Same. * testsuite/20_util/weak_ptr/comparison/cmp_neg.cc: Same. * testsuite/23_containers/deque/requirements/dr438/assign_neg.cc: Same. * testsuite/23_containers/deque/requirements/dr438/ constructor_1_neg.cc: Same. * testsuite/23_containers/deque/requirements/dr438/ constructor_2_neg.cc: Same. * testsuite/23_containers/deque/requirements/dr438/insert_neg.cc: Same. * testsuite/23_containers/forward_list/capacity/1.cc: Same. * testsuite/23_containers/forward_list/requirements/dr438/ assign_neg.cc: Same. * testsuite/23_containers/forward_list/requirements/dr438/ constructor_1_neg.cc: Same. * testsuite/23_containers/forward_list/requirements/dr438/ constructor_2_neg.cc: Same. * testsuite/23_containers/forward_list/requirements/dr438/ insert_neg.cc: Same. * testsuite/23_containers/list/capacity/29134.cc: Same. * testsuite/23_containers/list/requirements/dr438/assign_neg.cc: Same. * testsuite/23_containers/list/requirements/dr438/ constructor_1_neg.cc: Same. * testsuite/23_containers/list/requirements/dr438/ constructor_2_neg.cc: Same. * testsuite/23_containers/list/requirements/dr438/insert_neg.cc: Same. * testsuite/23_containers/vector/bool/capacity/29134.cc: Same. * testsuite/23_containers/vector/bool/modifiers/insert/31370.cc: Same. * testsuite/23_containers/vector/requirements/dr438/assign_neg.cc: Same. * testsuite/23_containers/vector/requirements/dr438/ constructor_1_neg.cc: Same. * testsuite/23_containers/vector/requirements/dr438/ constructor_2_neg.cc: Same. * testsuite/23_containers/vector/requirements/dr438/insert_neg.cc: Same. * testsuite/25_algorithms/sort/35588.cc: Same. * testsuite/27_io/ios_base/cons/assign_neg.cc: Same. * testsuite/27_io/ios_base/cons/copy_neg.cc: Same. * testsuite/ext/profile/mutex_extensions_neg.cc: Same. * testsuite/ext/profile/profiler_algos.cc: Same. * testsuite/ext/type_traits/add_unsigned_floating_neg.cc: Same. * testsuite/ext/type_traits/add_unsigned_integer_neg.cc: Same. * testsuite/ext/type_traits/remove_unsigned_floating_neg.cc: Same. * testsuite/ext/type_traits/remove_unsigned_integer_neg.cc: Same. * testsuite/tr1/2_general_utilities/shared_ptr/cons/43820_neg.cc: Same. From-SVN: r169421
2011-01-30 23:39:36 +01:00
_GLIBCXX_END_NAMESPACE_VERSION
} // namespace
} // extern "C++"
type_traits.h: New. 2006-09-18 Benjamin Kosnik <bkoz@redhat.com> Peter Doerfler <gcc@pdoerfler.com> Paolo Carlini <pcarlini@suse.de> * include/ext/type_traits.h: New. (__conditional_type): New. (__numeric_traits): New. (__add_unsigned): New. (__remove_unsigned): New. (__enable_if): New. * include/Makefile.am: Add. * include/Makefile.in: Regenerate. * include/ext/pb_ds/detail/type_utils.hpp: Use ext include, remove duplicates. * include/tr1/hashtable_policy.h (IF): Use __conditional_type. (_Max_digits10): Same. (identity): Use _Identity. (extract1st): Use _Select1st. * include/tr1/random (_Select): Use __conditional_type. (_To_Unsigned_Type): Use __add_unsigned. Linebreak fixups. * include/bits/locale_facets.tcc (__to_unsigned_type): Remove, use __add_unsigned. * include/tr1/random.tcc: Fixups as above. * include/tr1/unordered_map: Same. * include/tr1/hashtable: Same. * include/tr1/unordered_set: Same. * include/ext/pb_ds/detail/gp_hash_table_map_/ standard_policies.hpp: Same. * include/ext/pb_ds/detail/standard_policies.hpp: Same. * include/ext/pb_ds/detail/typelist/typelist_filter.hpp: Same. * include/ext/pb_ds/detail/binary_heap_/binary_heap_.hpp: Same. * include/ext/pb_ds/detail/type_utils.hpp: Same. * include/ext/pb_ds/trie_policy.hpp: Same. * docs/html/ext/pb_ds/string_trie_e_access_traits.html: Same. * include/bits/cpp_type_traits.h (__enable_if): Move to ext, make boolean argument first. * include/bits/locale_facets.h: Fixups for __enable_if argument and namespace switch. * include/bits/stl_algobase.h: Same. * include/bits/stl_algo.h: Same. * include/bits/stl_iterator.h: Same. * include/bits/streambuf_iterator.h: Same. * include/debug/safe_iterator.h: Same. * include/tr1/hashtable_policy.h: Same. * include/tr1/cmath: Same. * include/tr1/functional: Same. * include/tr1/functional_iterate.h: Same. * include/std/std_streambuf.h: Same. * include/c_std/std_cmath.h: Same. * testsuite/util/testsuite_tr1.h: Same. * testsuite/util/performance/assoc/multimap_common_type.hpp: Same. Co-Authored-By: Paolo Carlini <pcarlini@suse.de> Co-Authored-By: Peter Doerfler <gcc@pdoerfler.com> From-SVN: r117024
2006-09-18 15:30:56 +02:00
#endif