Commit 7c3e9502 by Benjamin Kosnik Committed by Benjamin Kosnik

re PR libstdc++/36104 (gnu-versioned-namespace is broken)

2011-01-14  Benjamin Kosnik  <bkoz@redhat.com>

	PR libstdc++/36104
	* include/Makefile.am (bits_sup_headers, stamp-bits-sup): New.
	* include/Makefile.in: Regenerate.
	* libsupc++/Makefile.am (std_HEADERS, bits_HEADERS): New.
	(install-stdHEADERS, install-bitsHEADERS): New.
	* libsupc++/Makefile.in: Regenerate.

	* include/bits/c++config: Update for inline namespaces.
	* libsupc++/cxxabi-forced.h: To...
	* libsupc++/cxxabi_forced.h: ...this.
	* libsupc++/hash_bytes.h: Separate file.
	* libsupc++/typeinfo: Use it.
	* libsupc++/exception: Adjust for bits subdirectory.
	* libsupc++/eh_aux_runtime.cc: Same.
	* libsupc++/eh_ptr.cc: Same.
	* libsupc++/new_op.cc: Same.
	* libsupc++/exception_defines.h: Same.
	* libsupc++/nested_exception.h: Same.
	* libsupc++/eh_terminate.cc: Same.
	* libsupc++/vec.cc: Same.
	* libsupc++/vterminate.cc: Same.
	* libsupc++/exception_ptr.h: Same.
	* libsupc++/eh_personality.cc: Same.
	* libsupc++/eh_call.cc: Same.
	* libsupc++/new_opnt.cc: Same.
	* libsupc++/hash_bytes.cc: Same.
	* config/cpu/arm/cxxabi_tweaks.h: Same.
	* config/cpu/generic/cxxabi_tweaks.h: Same.
	* libsupc++/cxxabi.h: Same. Consolidate _GLIBCXX_NOTHROW defines.
	* include/std/bitset: Same.
	* include/ext/vstring.tcc: Same.
	* include/bits/hashtable.h: Same.
	* include/bits/functional_hash.h: Same.
	* include/bits/hashtable_policy.h: Same.
	* include/bits/basic_string.h: Same.
	* include/bits/istream.tcc: Same.
	* include/bits/ostream.tcc: Same.
	* include/bits/algorithmfwd.h: Same.
	* include/bits/basic_string.tcc: Same.
	* include/bits/ostream_insert.h: Same.
	* include/bits/fstream.tcc: Same.
	* include/bits/functexcept.h: Same.

	* doc/doxygen/user.cfg.in: Adjust names.

	* testsuite/ext/profile/mutex_extensions_neg.cc: Adjust line numbers.

From-SVN: r168831
parent 6227ed7d
2011-01-14 Benjamin Kosnik <bkoz@redhat.com>
PR libstdc++/36104
* include/Makefile.am (bits_sup_headers, stamp-bits-sup): New.
* include/Makefile.in: Regenerate.
* libsupc++/Makefile.am (std_HEADERS, bits_HEADERS): New.
(install-stdHEADERS, install-bitsHEADERS): New.
* libsupc++/Makefile.in: Regenerate.
* include/bits/c++config: Update for inline namespaces.
* libsupc++/cxxabi-forced.h: To...
* libsupc++/cxxabi_forced.h: ...this.
* libsupc++/hash_bytes.h: Separate file.
* libsupc++/typeinfo: Use it.
* libsupc++/exception: Adjust for bits subdirectory.
* libsupc++/eh_aux_runtime.cc: Same.
* libsupc++/eh_ptr.cc: Same.
* libsupc++/new_op.cc: Same.
* libsupc++/exception_defines.h: Same.
* libsupc++/nested_exception.h: Same.
* libsupc++/eh_terminate.cc: Same.
* libsupc++/vec.cc: Same.
* libsupc++/vterminate.cc: Same.
* libsupc++/exception_ptr.h: Same.
* libsupc++/eh_personality.cc: Same.
* libsupc++/eh_call.cc: Same.
* libsupc++/new_opnt.cc: Same.
* libsupc++/hash_bytes.cc: Same.
* config/cpu/arm/cxxabi_tweaks.h: Same.
* config/cpu/generic/cxxabi_tweaks.h: Same.
* libsupc++/cxxabi.h: Same. Consolidate _GLIBCXX_NOTHROW defines.
* include/std/bitset: Same.
* include/ext/vstring.tcc: Same.
* include/bits/hashtable.h: Same.
* include/bits/functional_hash.h: Same.
* include/bits/hashtable_policy.h: Same.
* include/bits/basic_string.h: Same.
* include/bits/istream.tcc: Same.
* include/bits/ostream.tcc: Same.
* include/bits/algorithmfwd.h: Same.
* include/bits/basic_string.tcc: Same.
* include/bits/ostream_insert.h: Same.
* include/bits/fstream.tcc: Same.
* include/bits/functexcept.h: Same.
* doc/doxygen/user.cfg.in: Adjust names.
* testsuite/ext/profile/mutex_extensions_neg.cc: Adjust line numbers.
2011-01-14 Paolo Carlini <paolo.carlini@oracle.com> 2011-01-14 Paolo Carlini <paolo.carlini@oracle.com>
* testsuite/25_algorithms/is_permutation/check_type.cc: Minor * testsuite/25_algorithms/is_permutation/check_type.cc: Minor
......
// Control various target specific ABI tweaks. ARM version. // Control various target specific ABI tweaks. ARM version.
// Copyright (C) 2004, 2006, 2008, 2009 Free Software Foundation, Inc. // Copyright (C) 2004, 2006, 2008, 2009, 2011 Free Software Foundation, Inc.
// //
// This file is part of the GNU ISO C++ Library. This library is free // 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 // software; you can redistribute it and/or modify it under the
...@@ -22,8 +22,9 @@ ...@@ -22,8 +22,9 @@
// see the files COPYING3 and COPYING.RUNTIME respectively. If not, see // see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
// <http://www.gnu.org/licenses/>. // <http://www.gnu.org/licenses/>.
/** @file cxxabi_tweaks.h /** @file bits/cxxabi_tweaks.h
* The header provides an CPU-variable interface to the C++ ABI. * This is an internal header file, included by other library headers.
* Do not attempt to use it directly. @headername{cxxabi.h}
*/ */
#ifndef _CXXABI_TWEAKS_H #ifndef _CXXABI_TWEAKS_H
......
// Control various target specific ABI tweaks. Generic version. // Control various target specific ABI tweaks. Generic version.
// Copyright (C) 2004, 2006, 2008, 2009 Free Software Foundation, Inc. // Copyright (C) 2004, 2006, 2008, 2009, 2011 Free Software Foundation, Inc.
// //
// This file is part of the GNU ISO C++ Library. This library is free // 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 // software; you can redistribute it and/or modify it under the
...@@ -22,8 +22,9 @@ ...@@ -22,8 +22,9 @@
// see the files COPYING3 and COPYING.RUNTIME respectively. If not, see // see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
// <http://www.gnu.org/licenses/>. // <http://www.gnu.org/licenses/>.
/** @file cxxabi_tweaks.h /** @file bits/cxxabi_tweaks.h
* The header provides an CPU-variable interface to the C++ ABI. * This is an internal header file, included by other library headers.
* Do not attempt to use it directly. @headername{cxxabi.h}
*/ */
#ifndef _CXXABI_TWEAKS_H #ifndef _CXXABI_TWEAKS_H
......
...@@ -586,7 +586,7 @@ WARN_LOGFILE = ...@@ -586,7 +586,7 @@ WARN_LOGFILE =
INPUT = @srcdir@/doc/doxygen/doxygroups.cc \ INPUT = @srcdir@/doc/doxygen/doxygroups.cc \
@srcdir@/libsupc++/cxxabi.h \ @srcdir@/libsupc++/cxxabi.h \
@srcdir@/libsupc++/cxxabi-forced.h \ @srcdir@/libsupc++/cxxabi_forced.h \
@srcdir@/libsupc++/exception \ @srcdir@/libsupc++/exception \
@srcdir@/libsupc++/exception_defines.h \ @srcdir@/libsupc++/exception_defines.h \
@srcdir@/libsupc++/exception_ptr.h \ @srcdir@/libsupc++/exception_ptr.h \
......
## Makefile for the include subdirectory of the GNU C++ Standard library. ## Makefile for the include subdirectory of the GNU C++ Standard library.
## ##
## Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 ## Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010,
## 2011
## Free Software Foundation, Inc. ## Free Software Foundation, Inc.
## ##
## This file is part of the libstdc++ version 3 distribution. ## This file is part of the libstdc++ version 3 distribution.
...@@ -172,6 +173,14 @@ bits_headers = \ ...@@ -172,6 +173,14 @@ bits_headers = \
${bits_srcdir}/valarray_after.h \ ${bits_srcdir}/valarray_after.h \
${bits_srcdir}/vector.tcc ${bits_srcdir}/vector.tcc
bits_sup_srcdir = ${glibcxx_srcdir}/libsupc++
bits_sup_headers = \
${bits_sup_srcdir}/cxxabi_forced.h \
${bits_sup_srcdir}/exception_defines.h \
${bits_sup_srcdir}/exception_ptr.h \
${bits_sup_srcdir}/hash_bytes.h \
${bits_sup_srcdir}/nested_exception.h
backward_srcdir = ${glibcxx_srcdir}/include/backward backward_srcdir = ${glibcxx_srcdir}/include/backward
backward_builddir = ./backward backward_builddir = ./backward
backward_headers = \ backward_headers = \
...@@ -888,7 +897,7 @@ endif ...@@ -888,7 +897,7 @@ endif
# List of all timestamp files. By keeping only one copy of this list, both # List of all timestamp files. By keeping only one copy of this list, both
# CLEANFILES and all-local are kept up-to-date. # CLEANFILES and all-local are kept up-to-date.
allstamped = \ allstamped = \
stamp-std stamp-bits stamp-c_base stamp-c_compatibility \ stamp-std stamp-bits stamp-bits-sup stamp-c_base stamp-c_compatibility \
stamp-backward stamp-ext stamp-pb stamp-tr1 stamp-decimal \ stamp-backward stamp-ext stamp-pb stamp-tr1 stamp-decimal \
stamp-debug stamp-parallel stamp-profile stamp-profile-impl \ stamp-debug stamp-parallel stamp-profile stamp-profile-impl \
stamp-host stamp-host
...@@ -917,6 +926,10 @@ stamp-bits: ${bits_headers} ...@@ -917,6 +926,10 @@ stamp-bits: ${bits_headers}
@-cd ${bits_builddir} && $(LN_S) $? . 2>/dev/null @-cd ${bits_builddir} && $(LN_S) $? . 2>/dev/null
@$(STAMP) stamp-bits @$(STAMP) stamp-bits
stamp-bits-sup: stamp-bits ${bits_sup_headers}
@-cd ${bits_builddir} && $(LN_S) $? . 2>/dev/null
@$(STAMP) stamp-bits-sup
stamp-c_base: ${c_base_headers} stamp-c_base: ${c_base_headers}
@-mkdir -p ${c_base_builddir} @-mkdir -p ${c_base_builddir}
@-cd ${c_base_builddir} && $(LN_S) $? . 2>/dev/null @-cd ${c_base_builddir} && $(LN_S) $? . 2>/dev/null
...@@ -1071,14 +1084,14 @@ ${host_builddir}/c++config.h: ${CONFIG_HEADER} \ ...@@ -1071,14 +1084,14 @@ ${host_builddir}/c++config.h: ${CONFIG_HEADER} \
stamp-namespace-version \ stamp-namespace-version \
stamp-visibility stamp-visibility
@date=`cat ${toplevel_srcdir}/gcc/DATESTAMP` ;\ @date=`cat ${toplevel_srcdir}/gcc/DATESTAMP` ;\
nsa_version=`cat stamp-namespace-version` ;\ ns_version=`cat stamp-namespace-version` ;\
visibility=`cat stamp-visibility` ;\ visibility=`cat stamp-visibility` ;\
ldbl_compat='s,g,g,' ;\ ldbl_compat='s,g,g,' ;\
grep "^[ ]*#[ ]*define[ ][ ]*_GLIBCXX_LONG_DOUBLE_COMPAT[ ][ ]*1[ ]*$$" \ grep "^[ ]*#[ ]*define[ ][ ]*_GLIBCXX_LONG_DOUBLE_COMPAT[ ][ ]*1[ ]*$$" \
${CONFIG_HEADER} > /dev/null 2>&1 \ ${CONFIG_HEADER} > /dev/null 2>&1 \
&& ldbl_compat='s,^#undef _GLIBCXX_LONG_DOUBLE_COMPAT$$,#define _GLIBCXX_LONG_DOUBLE_COMPAT 1,' ;\ && ldbl_compat='s,^#undef _GLIBCXX_LONG_DOUBLE_COMPAT$$,#define _GLIBCXX_LONG_DOUBLE_COMPAT 1,' ;\
sed -e "s,define __GLIBCXX__,define __GLIBCXX__ $$date," \ sed -e "s,define __GLIBCXX__,define __GLIBCXX__ $$date," \
-e "s,define _GLIBCXX_NAMESPACE_ASSOCIATION_VERSION, define _GLIBCXX_NAMESPACE_ASSOCIATION_VERSION $$nsa_version," \ -e "s,define _GLIBCXX_INLINE_VERSION, define _GLIBCXX_INLINE_VERSION $$ns_version," \
-e "s,define _GLIBCXX_HAVE_ATTRIBUTE_VISIBILITY, define _GLIBCXX_HAVE_ATTRIBUTE_VISIBILITY $$visibility," \ -e "s,define _GLIBCXX_HAVE_ATTRIBUTE_VISIBILITY, define _GLIBCXX_HAVE_ATTRIBUTE_VISIBILITY $$visibility," \
-e "$$ldbl_compat" \ -e "$$ldbl_compat" \
< ${glibcxx_srcdir}/include/bits/c++config > $@ ;\ < ${glibcxx_srcdir}/include/bits/c++config > $@ ;\
......
...@@ -423,6 +423,14 @@ bits_headers = \ ...@@ -423,6 +423,14 @@ bits_headers = \
${bits_srcdir}/valarray_after.h \ ${bits_srcdir}/valarray_after.h \
${bits_srcdir}/vector.tcc ${bits_srcdir}/vector.tcc
bits_sup_srcdir = ${glibcxx_srcdir}/libsupc++
bits_sup_headers = \
${bits_sup_srcdir}/cxxabi_forced.h \
${bits_sup_srcdir}/exception_defines.h \
${bits_sup_srcdir}/exception_ptr.h \
${bits_sup_srcdir}/hash_bytes.h \
${bits_sup_srcdir}/nested_exception.h
backward_srcdir = ${glibcxx_srcdir}/include/backward backward_srcdir = ${glibcxx_srcdir}/include/backward
backward_builddir = ./backward backward_builddir = ./backward
backward_headers = \ backward_headers = \
...@@ -1125,7 +1133,7 @@ PCHFLAGS = -x c++-header -nostdinc++ $(CXXFLAGS) ...@@ -1125,7 +1133,7 @@ PCHFLAGS = -x c++-header -nostdinc++ $(CXXFLAGS)
# List of all timestamp files. By keeping only one copy of this list, both # List of all timestamp files. By keeping only one copy of this list, both
# CLEANFILES and all-local are kept up-to-date. # CLEANFILES and all-local are kept up-to-date.
allstamped = \ allstamped = \
stamp-std stamp-bits stamp-c_base stamp-c_compatibility \ stamp-std stamp-bits stamp-bits-sup stamp-c_base stamp-c_compatibility \
stamp-backward stamp-ext stamp-pb stamp-tr1 stamp-decimal \ stamp-backward stamp-ext stamp-pb stamp-tr1 stamp-decimal \
stamp-debug stamp-parallel stamp-profile stamp-profile-impl \ stamp-debug stamp-parallel stamp-profile stamp-profile-impl \
stamp-host stamp-host
...@@ -1316,6 +1324,10 @@ stamp-bits: ${bits_headers} ...@@ -1316,6 +1324,10 @@ stamp-bits: ${bits_headers}
@-cd ${bits_builddir} && $(LN_S) $? . 2>/dev/null @-cd ${bits_builddir} && $(LN_S) $? . 2>/dev/null
@$(STAMP) stamp-bits @$(STAMP) stamp-bits
stamp-bits-sup: stamp-bits ${bits_sup_headers}
@-cd ${bits_builddir} && $(LN_S) $? . 2>/dev/null
@$(STAMP) stamp-bits-sup
stamp-c_base: ${c_base_headers} stamp-c_base: ${c_base_headers}
@-mkdir -p ${c_base_builddir} @-mkdir -p ${c_base_builddir}
@-cd ${c_base_builddir} && $(LN_S) $? . 2>/dev/null @-cd ${c_base_builddir} && $(LN_S) $? . 2>/dev/null
...@@ -1464,14 +1476,14 @@ ${host_builddir}/c++config.h: ${CONFIG_HEADER} \ ...@@ -1464,14 +1476,14 @@ ${host_builddir}/c++config.h: ${CONFIG_HEADER} \
stamp-namespace-version \ stamp-namespace-version \
stamp-visibility stamp-visibility
@date=`cat ${toplevel_srcdir}/gcc/DATESTAMP` ;\ @date=`cat ${toplevel_srcdir}/gcc/DATESTAMP` ;\
nsa_version=`cat stamp-namespace-version` ;\ ns_version=`cat stamp-namespace-version` ;\
visibility=`cat stamp-visibility` ;\ visibility=`cat stamp-visibility` ;\
ldbl_compat='s,g,g,' ;\ ldbl_compat='s,g,g,' ;\
grep "^[ ]*#[ ]*define[ ][ ]*_GLIBCXX_LONG_DOUBLE_COMPAT[ ][ ]*1[ ]*$$" \ grep "^[ ]*#[ ]*define[ ][ ]*_GLIBCXX_LONG_DOUBLE_COMPAT[ ][ ]*1[ ]*$$" \
${CONFIG_HEADER} > /dev/null 2>&1 \ ${CONFIG_HEADER} > /dev/null 2>&1 \
&& ldbl_compat='s,^#undef _GLIBCXX_LONG_DOUBLE_COMPAT$$,#define _GLIBCXX_LONG_DOUBLE_COMPAT 1,' ;\ && ldbl_compat='s,^#undef _GLIBCXX_LONG_DOUBLE_COMPAT$$,#define _GLIBCXX_LONG_DOUBLE_COMPAT 1,' ;\
sed -e "s,define __GLIBCXX__,define __GLIBCXX__ $$date," \ sed -e "s,define __GLIBCXX__,define __GLIBCXX__ $$date," \
-e "s,define _GLIBCXX_NAMESPACE_ASSOCIATION_VERSION, define _GLIBCXX_NAMESPACE_ASSOCIATION_VERSION $$nsa_version," \ -e "s,define _GLIBCXX_INLINE_VERSION, define _GLIBCXX_INLINE_VERSION $$ns_version," \
-e "s,define _GLIBCXX_HAVE_ATTRIBUTE_VISIBILITY, define _GLIBCXX_HAVE_ATTRIBUTE_VISIBILITY $$visibility," \ -e "s,define _GLIBCXX_HAVE_ATTRIBUTE_VISIBILITY, define _GLIBCXX_HAVE_ATTRIBUTE_VISIBILITY $$visibility," \
-e "$$ldbl_compat" \ -e "$$ldbl_compat" \
< ${glibcxx_srcdir}/include/bits/c++config > $@ ;\ < ${glibcxx_srcdir}/include/bits/c++config > $@ ;\
......
...@@ -804,7 +804,7 @@ _GLIBCXX_BEGIN_NESTED_NAMESPACE(std, _GLIBCXX_STD_P) ...@@ -804,7 +804,7 @@ _GLIBCXX_BEGIN_NESTED_NAMESPACE(std, _GLIBCXX_STD_P)
_GLIBCXX_END_NESTED_NAMESPACE _GLIBCXX_END_NESTED_NAMESPACE
#ifdef _GLIBCXX_NAMESPACE_ASSOCIATION_PARALLEL #ifdef _GLIBCXX_PARALLEL
# include <parallel/algorithmfwd.h> # include <parallel/algorithmfwd.h>
#endif #endif
......
// Components for manipulating sequences of characters -*- C++ -*- // Components for manipulating sequences of characters -*- C++ -*-
// Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, // Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005,
// 2006, 2007, 2008, 2009, 2010 // 2006, 2007, 2008, 2009, 2010, 2011
// Free Software Foundation, Inc. // Free Software Foundation, Inc.
// //
// This file is part of the GNU ISO C++ Library. This library is free // This file is part of the GNU ISO C++ Library. This library is free
......
// Components for manipulating sequences of characters -*- C++ -*- // Components for manipulating sequences of characters -*- C++ -*-
// Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, // Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005,
// 2006, 2007, 2008, 2009, 2010 // 2006, 2007, 2008, 2009, 2010, 2011
// Free Software Foundation, Inc. // Free Software Foundation, Inc.
// //
// This file is part of the GNU ISO C++ Library. This library is free // This file is part of the GNU ISO C++ Library. This library is free
...@@ -41,7 +41,7 @@ ...@@ -41,7 +41,7 @@
#pragma GCC system_header #pragma GCC system_header
#include <cxxabi-forced.h> #include <bits/cxxabi_forced.h>
_GLIBCXX_BEGIN_NAMESPACE(std) _GLIBCXX_BEGIN_NAMESPACE(std)
......
// Predefined symbols and macros -*- C++ -*- // Predefined symbols and macros -*- C++ -*-
// Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, // Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005,
// 2006, 2007, 2008, 2009, 2010 Free Software Foundation, Inc. // 2006, 2007, 2008, 2009, 2010, 2011 Free Software Foundation, Inc.
// //
// This file is part of the GNU ISO C++ Library. This library is free // 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 // software; you can redistribute it and/or modify it under the
...@@ -32,7 +32,7 @@ ...@@ -32,7 +32,7 @@
#define _GLIBCXX_CXX_CONFIG_H 1 #define _GLIBCXX_CXX_CONFIG_H 1
// The current version of the C++ library in compressed ISO date format. // The current version of the C++ library in compressed ISO date format.
#define __GLIBCXX__ #define __GLIBCXX__
// Macros for various attributes. // Macros for various attributes.
#ifndef _GLIBCXX_PURE #ifndef _GLIBCXX_PURE
...@@ -49,7 +49,7 @@ ...@@ -49,7 +49,7 @@
#ifndef _GLIBCXX_NOTHROW #ifndef _GLIBCXX_NOTHROW
# ifdef __cplusplus # ifdef __cplusplus
# define _GLIBCXX_NOTHROW throw() # define _GLIBCXX_NOTHROW throw()
# else # else
# define _GLIBCXX_NOTHROW __attribute__((__nothrow__)) # define _GLIBCXX_NOTHROW __attribute__((__nothrow__))
# endif # endif
...@@ -87,7 +87,7 @@ namespace std ...@@ -87,7 +87,7 @@ namespace std
{ {
typedef __SIZE_TYPE__ size_t; typedef __SIZE_TYPE__ size_t;
typedef __PTRDIFF_TYPE__ ptrdiff_t; typedef __PTRDIFF_TYPE__ ptrdiff_t;
#ifdef __GXX_EXPERIMENTAL_CXX0X__ #ifdef __GXX_EXPERIMENTAL_CXX0X__
typedef decltype(nullptr) nullptr_t; typedef decltype(nullptr) nullptr_t;
#endif #endif
...@@ -103,23 +103,19 @@ namespace std ...@@ -103,23 +103,19 @@ namespace std
#ifndef _GLIBCXX_CONSTEXPR #ifndef _GLIBCXX_CONSTEXPR
# ifdef __GXX_EXPERIMENTAL_CXX0X__ # ifdef __GXX_EXPERIMENTAL_CXX0X__
# define _GLIBCXX_CONSTEXPR constexpr # define _GLIBCXX_CONSTEXPR constexpr
# else
# define _GLIBCXX_CONSTEXPR
# endif
#endif
#ifndef _GLIBCXX_USE_CONSTEXPR
# ifdef __GXX_EXPERIMENTAL_CXX0X__
# define _GLIBCXX_USE_CONSTEXPR constexpr # define _GLIBCXX_USE_CONSTEXPR constexpr
# else # else
# define _GLIBCXX_CONSTEXPR
# define _GLIBCXX_USE_CONSTEXPR const # define _GLIBCXX_USE_CONSTEXPR const
# endif # endif
#endif #endif
// Macros for activating various namespace association modes. // Macros for activating various inline namespaces.
// _GLIBCXX_NAMESPACE_ASSOCIATION_DEBUG //
// _GLIBCXX_NAMESPACE_ASSOCIATION_PARALLEL // _GLIBCXX_NAMESPACE_DEBUG
// _GLIBCXX_NAMESPACE_ASSOCIATION_VERSION // _GLIBCXX_NAMESPACE_PARALLEL
// _GLIBCXX_NAMESPACE_PROFILE
// _GLIBCXX_NAMESPACE_VERSION
// Guide to libstdc++ namespaces. // Guide to libstdc++ namespaces.
/* /*
...@@ -127,6 +123,7 @@ namespace std ...@@ -127,6 +123,7 @@ namespace std
{ {
namespace __debug { } namespace __debug { }
namespace __parallel { } namespace __parallel { }
namespace __profile { }
namespace __norm { } // __normative, __shadow, __replaced namespace __norm { } // __normative, __shadow, __replaced
namespace __cxx1998 { } namespace __cxx1998 { }
...@@ -135,26 +132,26 @@ namespace std ...@@ -135,26 +132,26 @@ namespace std
*/ */
#ifdef _GLIBCXX_DEBUG #ifdef _GLIBCXX_DEBUG
# define _GLIBCXX_NAMESPACE_ASSOCIATION_DEBUG 1 # define _GLIBCXX_INLINE_DEBUG 1
#endif #endif
#ifdef _GLIBCXX_PARALLEL #ifdef _GLIBCXX_PARALLEL
# define _GLIBCXX_NAMESPACE_ASSOCIATION_PARALLEL 1 # define _GLIBCXX_INLINE_PARALLEL 1
#endif #endif
// Namespace association for profile // Namespace association for profile.
#ifdef _GLIBCXX_PROFILE #ifdef _GLIBCXX_PROFILE
# define _GLIBCXX_NAMESPACE_ASSOCIATION_PROFILE 1 # define _GLIBCXX_INLINE_PROFILE 1
#endif #endif
#define _GLIBCXX_NAMESPACE_ASSOCIATION_VERSION #define _GLIBCXX_INLINE_VERSION
// Defined if any namespace association modes are active. // Defined if inline namespaces modes are active.
#if _GLIBCXX_NAMESPACE_ASSOCIATION_DEBUG \ #if _GLIBCXX_INLINE_DEBUG \
|| _GLIBCXX_NAMESPACE_ASSOCIATION_PARALLEL \ || _GLIBCXX_INLINE_PARALLEL \
|| _GLIBCXX_NAMESPACE_ASSOCIATION_PROFILE \ || _GLIBCXX_INLINE_PROFILE \
|| _GLIBCXX_NAMESPACE_ASSOCIATION_VERSION || _GLIBCXX_INLINE_VERSION
# define _GLIBCXX_USE_NAMESPACE_ASSOCIATION 1 # define _GLIBCXX_USE_INLINE_NAMESPACES 1
#endif #endif
// Macros for namespace scope. Either namespace std:: or the name // Macros for namespace scope. Either namespace std:: or the name
...@@ -169,7 +166,7 @@ namespace std ...@@ -169,7 +166,7 @@ namespace std
// _GLIBCXX_END_NAMESPACE // _GLIBCXX_END_NAMESPACE
// _GLIBCXX_BEGIN_NESTED_NAMESPACE // _GLIBCXX_BEGIN_NESTED_NAMESPACE
// _GLIBCXX_END_NESTED_NAMESPACE // _GLIBCXX_END_NESTED_NAMESPACE
#ifndef _GLIBCXX_USE_NAMESPACE_ASSOCIATION #ifndef _GLIBCXX_USE_INLINE_NAMESPACES
# define _GLIBCXX_STD_D _GLIBCXX_STD # define _GLIBCXX_STD_D _GLIBCXX_STD
# define _GLIBCXX_STD_P _GLIBCXX_STD # define _GLIBCXX_STD_P _GLIBCXX_STD
# define _GLIBCXX_STD_PR _GLIBCXX_STD # define _GLIBCXX_STD_PR _GLIBCXX_STD
...@@ -180,7 +177,7 @@ namespace std ...@@ -180,7 +177,7 @@ namespace std
# define _GLIBCXX_END_NAMESPACE } # define _GLIBCXX_END_NAMESPACE }
#else #else
# if _GLIBCXX_NAMESPACE_ASSOCIATION_VERSION // && not anything else # if _GLIBCXX_INLINE_VERSION // && not anything else
# define _GLIBCXX_STD_D _GLIBCXX_STD # define _GLIBCXX_STD_D _GLIBCXX_STD
# define _GLIBCXX_STD_P _GLIBCXX_STD # define _GLIBCXX_STD_P _GLIBCXX_STD
# define _GLIBCXX_STD _6 # define _GLIBCXX_STD _6
...@@ -189,37 +186,37 @@ namespace std ...@@ -189,37 +186,37 @@ namespace std
# endif # endif
// debug // debug
# if _GLIBCXX_NAMESPACE_ASSOCIATION_DEBUG && !_GLIBCXX_NAMESPACE_ASSOCIATION_PARALLEL && !_GLIBCXX_NAMESPACE_ASSOCIATION_PROFILE # if _GLIBCXX_INLINE_DEBUG && !_GLIBCXX_INLINE_PARALLEL && !_GLIBCXX_INLINE_PROFILE
# define _GLIBCXX_STD_D __norm # define _GLIBCXX_STD_D __norm
# define _GLIBCXX_STD_P _GLIBCXX_STD # define _GLIBCXX_STD_P _GLIBCXX_STD
# define _GLIBCXX_STD __cxx1998 # define _GLIBCXX_STD __cxx1998
# define _GLIBCXX_BEGIN_NAMESPACE(X) namespace X _GLIBCXX_VISIBILITY_ATTR(default) { # define _GLIBCXX_BEGIN_NAMESPACE(X) namespace X _GLIBCXX_VISIBILITY_ATTR(default) {
# define _GLIBCXX_END_NAMESPACE } # define _GLIBCXX_END_NAMESPACE }
# define _GLIBCXX_EXTERN_TEMPLATE -1 # define _GLIBCXX_EXTERN_TEMPLATE -1
# endif # endif
// parallel // parallel
# if _GLIBCXX_NAMESPACE_ASSOCIATION_PARALLEL && !_GLIBCXX_NAMESPACE_ASSOCIATION_DEBUG && !_GLIBCXX_NAMESPACE_ASSOCIATION_PROFILE # if _GLIBCXX_INLINE_PARALLEL && !_GLIBCXX_INLINE_DEBUG && !_GLIBCXX_INLINE_PROFILE
# define _GLIBCXX_STD_D _GLIBCXX_STD # define _GLIBCXX_STD_D _GLIBCXX_STD
# define _GLIBCXX_STD_P __norm # define _GLIBCXX_STD_P __norm
# define _GLIBCXX_STD __cxx1998 # define _GLIBCXX_STD __cxx1998
# define _GLIBCXX_BEGIN_NAMESPACE(X) namespace X _GLIBCXX_VISIBILITY_ATTR(default) { # define _GLIBCXX_BEGIN_NAMESPACE(X) namespace X _GLIBCXX_VISIBILITY_ATTR(default) {
# define _GLIBCXX_END_NAMESPACE } # define _GLIBCXX_END_NAMESPACE }
# endif # endif
// debug + parallel // debug + parallel
# if _GLIBCXX_NAMESPACE_ASSOCIATION_PARALLEL && _GLIBCXX_NAMESPACE_ASSOCIATION_DEBUG && !_GLIBCXX_NAMESPACE_ASSOCIATION_PROFILE # if _GLIBCXX_INLINE_PARALLEL && _GLIBCXX_INLINE_DEBUG && !_GLIBCXX_INLINE_PROFILE
# define _GLIBCXX_STD_D __norm # define _GLIBCXX_STD_D __norm
# define _GLIBCXX_STD_P __norm # define _GLIBCXX_STD_P __norm
# define _GLIBCXX_STD __cxx1998 # define _GLIBCXX_STD __cxx1998
# define _GLIBCXX_BEGIN_NAMESPACE(X) namespace X _GLIBCXX_VISIBILITY_ATTR(default) { # define _GLIBCXX_BEGIN_NAMESPACE(X) namespace X _GLIBCXX_VISIBILITY_ATTR(default) {
# define _GLIBCXX_END_NAMESPACE } # define _GLIBCXX_END_NAMESPACE }
# define _GLIBCXX_EXTERN_TEMPLATE -1 # define _GLIBCXX_EXTERN_TEMPLATE -1
# endif # endif
// profile // profile
# if _GLIBCXX_NAMESPACE_ASSOCIATION_PROFILE # if _GLIBCXX_INLINE_PROFILE
# if _GLIBCXX_NAMESPACE_ASSOCIATION_PARALLEL || _GLIBCXX_NAMESPACE_ASSOCIATION_DEBUG # if _GLIBCXX_INLINE_PARALLEL || _GLIBCXX_INLINE_DEBUG
# error Cannot use -D_GLIBCXX_PROFILE with -D_GLIBCXX_DEBUG or \ # error Cannot use -D_GLIBCXX_PROFILE with -D_GLIBCXX_DEBUG or \
-D_GLIBCXX_PARALLEL -D_GLIBCXX_PARALLEL
# endif # endif
...@@ -227,12 +224,12 @@ namespace std ...@@ -227,12 +224,12 @@ namespace std
# define _GLIBCXX_STD_P _GLIBCXX_STD # define _GLIBCXX_STD_P _GLIBCXX_STD
# define _GLIBCXX_STD_PR __norm # define _GLIBCXX_STD_PR __norm
# define _GLIBCXX_STD __cxx1998 # define _GLIBCXX_STD __cxx1998
# define _GLIBCXX_BEGIN_NAMESPACE(X) namespace X _GLIBCXX_VISIBILITY_ATTR(default) { # define _GLIBCXX_BEGIN_NAMESPACE(X) namespace X _GLIBCXX_VISIBILITY_ATTR(default) {
# define _GLIBCXX_END_NAMESPACE } # define _GLIBCXX_END_NAMESPACE }
# endif # endif
# if __NO_INLINE__ && !__GXX_WEAK__ # if __NO_INLINE__ && !__GXX_WEAK__
# warning currently using namespace associated mode which may fail \ # warning currently using inlined namespace mode which may fail \
without inlining due to lack of weak symbols without inlining due to lack of weak symbols
# endif # endif
...@@ -240,52 +237,52 @@ namespace std ...@@ -240,52 +237,52 @@ namespace std
# define _GLIBCXX_END_NESTED_NAMESPACE } } # define _GLIBCXX_END_NESTED_NAMESPACE } }
#endif #endif
// Namespace associations for debug mode. // Inline namespaces for debug mode.
#if _GLIBCXX_NAMESPACE_ASSOCIATION_DEBUG && !_GLIBCXX_NAMESPACE_ASSOCIATION_PROFILE #if _GLIBCXX_INLINE_DEBUG && !_GLIBCXX_INLINE_PROFILE
namespace std namespace std
{ {
namespace __norm { } namespace __norm { }
inline namespace __debug { } inline namespace __debug { }
inline namespace __cxx1998 { } inline namespace __cxx1998 { }
} }
#endif #endif
// Namespace associations for parallel mode. // Inline namespaces for parallel mode.
#if _GLIBCXX_NAMESPACE_ASSOCIATION_PARALLEL #if _GLIBCXX_INLINE_PARALLEL
namespace std namespace std
{ {
namespace __norm { } namespace __norm { }
inline namespace __parallel { } inline namespace __parallel { }
inline namespace __cxx1998 { } inline namespace __cxx1998 { }
} }
#endif #endif
// Namespace associations for profile mode // Inline namespaces for profile mode
#if _GLIBCXX_NAMESPACE_ASSOCIATION_PROFILE #if _GLIBCXX_INLINE_PROFILE
namespace std namespace std
{ {
namespace __norm { } namespace __norm { }
inline namespace __profile { } inline namespace __profile { }
inline namespace __cxx1998 { } inline namespace __cxx1998 { }
} }
#endif #endif
// Namespace associations for versioning mode. // Inline namespaces for versioning mode.
#if _GLIBCXX_NAMESPACE_ASSOCIATION_VERSION #if _GLIBCXX_INLINE_VERSION
namespace std namespace std
{ {
inline namespace _6 { } inline namespace _6 { }
} }
namespace __gnu_cxx namespace __gnu_cxx
{ {
inline namespace _6 { } inline namespace _6 { }
} }
namespace std namespace std
{ {
namespace tr1 namespace tr1
{ {
inline namespace _6 { } inline namespace _6 { }
} }
} }
...@@ -295,8 +292,8 @@ namespace std ...@@ -295,8 +292,8 @@ namespace std
// Define if compatibility should be provided for -mlong-double-64 // Define if compatibility should be provided for -mlong-double-64
#undef _GLIBCXX_LONG_DOUBLE_COMPAT #undef _GLIBCXX_LONG_DOUBLE_COMPAT
// Namespace associations for long double 128 mode. // Inline namespaces for long double 128 mode.
#if defined _GLIBCXX_LONG_DOUBLE_COMPAT && defined __LONG_DOUBLE_128__ #if defined _GLIBCXX_LONG_DOUBLE_COMPAT && defined __LONG_DOUBLE_128__
namespace std namespace std
{ {
inline namespace __gnu_cxx_ldbl128 { } inline namespace __gnu_cxx_ldbl128 { }
...@@ -341,11 +338,11 @@ namespace std ...@@ -341,11 +338,11 @@ namespace std
#else // !__cplusplus #else // !__cplusplus
# define _GLIBCXX_BEGIN_EXTERN_C # define _GLIBCXX_BEGIN_EXTERN_C
# define _GLIBCXX_END_EXTERN_C # define _GLIBCXX_END_EXTERN_C
# undef _GLIBCXX_BEGIN_NAMESPACE # undef _GLIBCXX_BEGIN_NAMESPACE
# undef _GLIBCXX_END_NAMESPACE # undef _GLIBCXX_END_NAMESPACE
# define _GLIBCXX_BEGIN_NAMESPACE(X) # define _GLIBCXX_BEGIN_NAMESPACE(X)
# define _GLIBCXX_END_NAMESPACE # define _GLIBCXX_END_NAMESPACE
#endif #endif
// First includes. // First includes.
...@@ -397,7 +394,7 @@ _GLIBCXX_BEGIN_NAMESPACE(std) ...@@ -397,7 +394,7 @@ _GLIBCXX_BEGIN_NAMESPACE(std)
// Avoid the use of assert, because we're trying to keep the <cassert> // Avoid the use of assert, because we're trying to keep the <cassert>
// include out of the mix. // include out of the mix.
inline void inline void
__replacement_assert(const char* __file, int __line, __replacement_assert(const char* __file, int __line,
const char* __function, const char* __condition) const char* __function, const char* __condition)
{ {
__builtin_printf("%s:%d: %s: Assertion '%s' failed.\n", __file, __line, __builtin_printf("%s:%d: %s: Assertion '%s' failed.\n", __file, __line,
...@@ -406,8 +403,8 @@ _GLIBCXX_BEGIN_NAMESPACE(std) ...@@ -406,8 +403,8 @@ _GLIBCXX_BEGIN_NAMESPACE(std)
} }
_GLIBCXX_END_NAMESPACE _GLIBCXX_END_NAMESPACE
#define __glibcxx_assert(_Condition) \ #define __glibcxx_assert(_Condition) \
do \ do \
{ \ { \
if (! (_Condition)) \ if (! (_Condition)) \
std::__replacement_assert(__FILE__, __LINE__, \ std::__replacement_assert(__FILE__, __LINE__, \
......
// File based streams -*- C++ -*- // File based streams -*- C++ -*-
// Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, // Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006,
// 2007, 2008, 2009, 2010 // 2007, 2008, 2009, 2010, 2011
// Free Software Foundation, Inc. // Free Software Foundation, Inc.
// //
// This file is part of the GNU ISO C++ Library. This library is free // This file is part of the GNU ISO C++ Library. This library is free
...@@ -38,7 +38,7 @@ ...@@ -38,7 +38,7 @@
#pragma GCC system_header #pragma GCC system_header
#include <cxxabi-forced.h> #include <bits/cxxabi_forced.h>
_GLIBCXX_BEGIN_NAMESPACE(std) _GLIBCXX_BEGIN_NAMESPACE(std)
......
// Function-Based Exception Support -*- C++ -*- // Function-Based Exception Support -*- C++ -*-
// Copyright (C) 2001, 2004, 2005, 2008, 2009, 2010 // Copyright (C) 2001, 2004, 2005, 2008, 2009, 2010, 2011
// Free Software Foundation, Inc. // Free Software Foundation, Inc.
// //
// This file is part of the GNU ISO C++ Library. This library is free // This file is part of the GNU ISO C++ Library. This library is free
...@@ -38,7 +38,7 @@ ...@@ -38,7 +38,7 @@
#define _FUNCTEXCEPT_H 1 #define _FUNCTEXCEPT_H 1
#include <bits/c++config.h> #include <bits/c++config.h>
#include <exception_defines.h> #include <bits/exception_defines.h>
_GLIBCXX_BEGIN_NAMESPACE(std) _GLIBCXX_BEGIN_NAMESPACE(std)
......
// functional_hash.h header -*- C++ -*- // functional_hash.h header -*- C++ -*-
// Copyright (C) 2007, 2008, 2009, 2010 Free Software Foundation, Inc. // Copyright (C) 2007, 2008, 2009, 2010, 2011 Free Software Foundation, Inc.
// //
// This file is part of the GNU ISO C++ Library. This library is free // 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 // software; you can redistribute it and/or modify it under the
...@@ -32,10 +32,10 @@ ...@@ -32,10 +32,10 @@
#pragma GCC system_header #pragma GCC system_header
#include <bits/c++config.h> #include <bits/hash_bytes.h>
_GLIBCXX_BEGIN_NAMESPACE(std)
namespace std
{
/** @defgroup hashes Hashes /** @defgroup hashes Hashes
* @ingroup functors * @ingroup functors
* *
...@@ -122,20 +122,6 @@ namespace std ...@@ -122,20 +122,6 @@ namespace std
#undef _Cxx_hashtable_define_trivial_hash #undef _Cxx_hashtable_define_trivial_hash
// Hash function implementation for the nontrivial specialization.
// All of them are based on a primitive that hashes a pointer to
// a byte array. The actual hash algorithm is not guaranteed to
// stay the same from release to release -- it may be updated or
// tuned to improve hash quality or speed.
size_t
_Hash_bytes(const void* __ptr, size_t __len, size_t __seed);
// A similar hash primitive, using the FNV hash algorithm. This
// algorithm is guaranteed to stay the same from release to release.
// (although it might not produce the same values on different machines.)
size_t
_Fnv_hash_bytes(const void* __ptr, size_t __len, size_t __seed);
struct _Hash_impl struct _Hash_impl
{ {
static size_t static size_t
...@@ -158,7 +144,7 @@ namespace std ...@@ -158,7 +144,7 @@ namespace std
{ {
static size_t static size_t
hash(const void* __ptr, size_t __clength, hash(const void* __ptr, size_t __clength,
size_t __seed = static_cast<size_t>(2166136261UL)) size_t __seed = static_cast<size_t>(2166136261UL))
{ return _Fnv_hash_bytes(__ptr, __clength, __seed); } { return _Fnv_hash_bytes(__ptr, __clength, __seed); }
template<typename _Tp> template<typename _Tp>
...@@ -196,6 +182,7 @@ namespace std ...@@ -196,6 +182,7 @@ namespace std
hash<long double>::operator()(long double __val) const; hash<long double>::operator()(long double __val) const;
// @} group hashes // @} group hashes
}
_GLIBCXX_END_NAMESPACE
#endif // _FUNCTIONAL_HASH_H #endif // _FUNCTIONAL_HASH_H
// istream classes -*- C++ -*- // istream classes -*- C++ -*-
// Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, // Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005,
// 2006, 2007, 2008, 2009, 2010 // 2006, 2007, 2008, 2009, 2010, 2011
// Free Software Foundation, Inc. // Free Software Foundation, Inc.
// //
// This file is part of the GNU ISO C++ Library. This library is free // This file is part of the GNU ISO C++ Library. This library is free
...@@ -38,7 +38,7 @@ ...@@ -38,7 +38,7 @@
#pragma GCC system_header #pragma GCC system_header
#include <cxxabi-forced.h> #include <bits/cxxabi_forced.h>
_GLIBCXX_BEGIN_NAMESPACE(std) _GLIBCXX_BEGIN_NAMESPACE(std)
......
// ostream classes -*- C++ -*- // ostream classes -*- C++ -*-
// Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, // Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005,
// 2006, 2007, 2008, 2009, 2010 // 2006, 2007, 2008, 2009, 2010, 2011
// Free Software Foundation, Inc. // Free Software Foundation, Inc.
// //
// This file is part of the GNU ISO C++ Library. This library is free // This file is part of the GNU ISO C++ Library. This library is free
...@@ -38,7 +38,7 @@ ...@@ -38,7 +38,7 @@
#pragma GCC system_header #pragma GCC system_header
#include <cxxabi-forced.h> #include <bits/cxxabi_forced.h>
_GLIBCXX_BEGIN_NAMESPACE(std) _GLIBCXX_BEGIN_NAMESPACE(std)
......
// Helpers for ostream inserters -*- C++ -*- // Helpers for ostream inserters -*- C++ -*-
// Copyright (C) 2007, 2008, 2009, 2010 Free Software Foundation, Inc. // Copyright (C) 2007, 2008, 2009, 2010, 2011 Free Software Foundation, Inc.
// //
// This file is part of the GNU ISO C++ Library. This library is free // 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 // software; you can redistribute it and/or modify it under the
...@@ -33,7 +33,7 @@ ...@@ -33,7 +33,7 @@
#pragma GCC system_header #pragma GCC system_header
#include <iosfwd> #include <iosfwd>
#include <cxxabi-forced.h> #include <bits/cxxabi_forced.h>
_GLIBCXX_BEGIN_NAMESPACE(std) _GLIBCXX_BEGIN_NAMESPACE(std)
......
// Versatile string -*- C++ -*- // Versatile string -*- C++ -*-
// Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010 // Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010, 2011
// Free Software Foundation, Inc. // Free Software Foundation, Inc.
// //
// This file is part of the GNU ISO C++ Library. This library is free // This file is part of the GNU ISO C++ Library. This library is free
...@@ -33,7 +33,7 @@ ...@@ -33,7 +33,7 @@
#pragma GCC system_header #pragma GCC system_header
#include <cxxabi-forced.h> #include <bits/cxxabi_forced.h>
_GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx) _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
......
// <bitset> -*- C++ -*- // <bitset> -*- C++ -*-
// Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 // Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010,
// 2011
// Free Software Foundation, Inc. // Free Software Foundation, Inc.
// //
// This file is part of the GNU ISO C++ Library. This library is free // This file is part of the GNU ISO C++ Library. This library is free
...@@ -49,7 +50,7 @@ ...@@ -49,7 +50,7 @@
#include <bits/functexcept.h> // For invalid_argument, out_of_range, #include <bits/functexcept.h> // For invalid_argument, out_of_range,
// overflow_error // overflow_error
#include <iosfwd> #include <iosfwd>
#include <cxxabi-forced.h> #include <bits/cxxabi_forced.h>
#define _GLIBCXX_BITSET_BITS_PER_WORD (__CHAR_BIT__ * sizeof(unsigned long)) #define _GLIBCXX_BITSET_BITS_PER_WORD (__CHAR_BIT__ * sizeof(unsigned long))
#define _GLIBCXX_BITSET_WORDS(__n) \ #define _GLIBCXX_BITSET_WORDS(__n) \
......
## Makefile for the GNU C++ Support library. ## Makefile for the GNU C++ Support library.
## ##
## Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, ## Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008,
## 2009, 2010 ## 2009, 2010, 2011
## Free Software Foundation, Inc. ## Free Software Foundation, Inc.
## ##
## Process this file with automake to produce Makefile.in. ## Process this file with automake to produce Makefile.in.
...@@ -31,10 +31,14 @@ toolexeclib_LTLIBRARIES = libsupc++.la ...@@ -31,10 +31,14 @@ toolexeclib_LTLIBRARIES = libsupc++.la
# 2) integrated libsupc++convenience.la that is to be a part of libstdc++.a # 2) integrated libsupc++convenience.la that is to be a part of libstdc++.a
noinst_LTLIBRARIES = libsupc++convenience.la noinst_LTLIBRARIES = libsupc++convenience.la
std_HEADERS = \
cxxabi.h exception initializer_list new typeinfo
headers = \ bits_HEADERS = \
exception new typeinfo cxxabi.h cxxabi-forced.h exception_defines.h \ cxxabi_forced.h hash_bytes.h \
initializer_list exception_ptr.h nested_exception.h exception_defines.h exception_ptr.h nested_exception.h
headers = $(std_HEADERS) $(bits_HEADERS)
if GLIBCXX_HOSTED if GLIBCXX_HOSTED
c_sources = \ c_sources = \
...@@ -88,12 +92,9 @@ sources = \ ...@@ -88,12 +92,9 @@ sources = \
vmi_class_type_info.cc \ vmi_class_type_info.cc \
vterminate.cc vterminate.cc
libsupc___la_SOURCES = $(sources) $(c_sources) libsupc___la_SOURCES = $(sources) $(c_sources)
libsupc__convenience_la_SOURCES = $(sources) $(c_sources) libsupc__convenience_la_SOURCES = $(sources) $(c_sources)
glibcxxinstalldir = $(gxx_include_dir)
glibcxxinstall_HEADERS = $(headers)
# AM_CXXFLAGS needs to be in each subdirectory so that it can be # AM_CXXFLAGS needs to be in each subdirectory so that it can be
# modified in a per-library or per-sub-library way. Need to manually # modified in a per-library or per-sub-library way. Need to manually
# set this option because CONFIG_CXXFLAGS has to be after # set this option because CONFIG_CXXFLAGS has to be after
...@@ -132,7 +133,7 @@ cp-demangle.o: cp-demangle.c ...@@ -132,7 +133,7 @@ cp-demangle.o: cp-demangle.c
$(C_COMPILE) -DIN_GLIBCPP_V3 -Wno-error -c $< $(C_COMPILE) -DIN_GLIBCPP_V3 -Wno-error -c $<
# libstdc++ libtool notes # Libtool notes
# 1) Need to explicitly set LTCXXCOMPILE so that AM_CXXFLAGS is # 1) Need to explicitly set LTCXXCOMPILE so that AM_CXXFLAGS is
# last. (That way, things like -O2 passed down from the toplevel can # last. (That way, things like -O2 passed down from the toplevel can
...@@ -169,21 +170,43 @@ CXXLINK = $(LIBTOOL) --tag CXX --tag disable-shared $(LIBTOOLFLAGS) \ ...@@ -169,21 +170,43 @@ CXXLINK = $(LIBTOOL) --tag CXX --tag disable-shared $(LIBTOOLFLAGS) \
--mode=link $(CXX) \ --mode=link $(CXX) \
$(OPT_LDFLAGS) $(SECTION_LDFLAGS) $(AM_CXXFLAGS) $(LTLDFLAGS) -o $@ $(OPT_LDFLAGS) $(SECTION_LDFLAGS) $(AM_CXXFLAGS) $(LTLDFLAGS) -o $@
# Install notes
# We have to have rules modified from the default to counteract SUN make # We have to have rules modified from the default to counteract SUN make
# prepending each of $(glibcxxinstall_HEADERS) with VPATH below. # prepending each of $(*_HEADERS) with VPATH below.
install-glibcxxinstallHEADERS: $(glibcxxinstall_HEADERS) stddir = $(gxx_include_dir)
bitsdir = $(gxx_include_dir)/bits
install-stdHEADERS: $(std_HEADERS)
@$(NORMAL_INSTALL) @$(NORMAL_INSTALL)
$(mkinstalldirs) $(DESTDIR)$(glibcxxinstalldir) $(mkinstalldirs) $(DESTDIR)$(stddir)
@list='$(glibcxxinstall_HEADERS)'; for p in $$list; do \ @list='$(std_HEADERS)'; for p in $$list; do \
q=`echo $$p | sed -e 's,.*/,,'`; \ q=`echo $$p | sed -e 's,.*/,,'`; \
if test -f "$$p"; then d= ; else d="$(srcdir)/"; fi; \ if test -f "$$p"; then d= ; else d="$(srcdir)/"; fi; \
echo " $(INSTALL_DATA) $$d$$p $(DESTDIR)$(glibcxxinstalldir)/$$q"; \ echo " $(INSTALL_DATA) $$d$$p $(DESTDIR)$(stddir)/$$q"; \
$(INSTALL_DATA) $$d$$p $(DESTDIR)$(glibcxxinstalldir)/$$q; \ $(INSTALL_DATA) $$d$$p $(DESTDIR)$(stddir)/$$q; \
done
install-bitsHEADERS: $(bits_HEADERS)
@$(NORMAL_INSTALL)
$(mkinstalldirs) $(DESTDIR)$(bitsdir)
@list='$(bits_HEADERS)'; for p in $$list; do \
q=`echo $$p | sed -e 's,.*/,,'`; \
if test -f "$$p"; then d= ; else d="$(srcdir)/"; fi; \
echo " $(INSTALL_DATA) $$d$$p $(DESTDIR)$(bitsdir)/$$q"; \
$(INSTALL_DATA) $$d$$p $(DESTDIR)$(bitsdir)/$$q; \
done
uninstall-stdHEADERS:
@$(NORMAL_UNINSTALL)
list='$(std_HEADERS)'; for p in $$list; do \
q=`echo $$p | sed -e 's,.*/,,'`; \
rm -f $(DESTDIR)$(stddir)/$$q; \
done done
uninstall-glibcxxinstallHEADERS: uninstall-bitsHEADERS:
@$(NORMAL_UNINSTALL) @$(NORMAL_UNINSTALL)
list='$(glibcxxinstall_HEADERS)'; for p in $$list; do \ list='$(bits_HEADERS)'; for p in $$list; do \
q=`echo $$p | sed -e 's,.*/,,'`; \ q=`echo $$p | sed -e 's,.*/,,'`; \
rm -f $(DESTDIR)$(glibcxxinstalldir)/$$q; \ rm -f $(DESTDIR)$(bitsdir)/$$q; \
done done
...@@ -37,7 +37,7 @@ build_triplet = @build@ ...@@ -37,7 +37,7 @@ build_triplet = @build@
host_triplet = @host@ host_triplet = @host@
target_triplet = @target@ target_triplet = @target@
DIST_COMMON = $(top_srcdir)/fragment.am $(srcdir)/Makefile.in \ DIST_COMMON = $(top_srcdir)/fragment.am $(srcdir)/Makefile.in \
$(srcdir)/Makefile.am $(glibcxxinstall_HEADERS) $(srcdir)/Makefile.am $(bits_HEADERS) $(std_HEADERS)
subdir = libsupc++ subdir = libsupc++
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/../config/acx.m4 \ am__aclocal_m4_deps = $(top_srcdir)/../config/acx.m4 \
...@@ -86,8 +86,8 @@ am__nobase_list = $(am__nobase_strip_setup); \ ...@@ -86,8 +86,8 @@ am__nobase_list = $(am__nobase_strip_setup); \
am__base_list = \ am__base_list = \
sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \
sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g'
am__installdirs = "$(DESTDIR)$(toolexeclibdir)" \ am__installdirs = "$(DESTDIR)$(toolexeclibdir)" "$(DESTDIR)$(bitsdir)" \
"$(DESTDIR)$(glibcxxinstalldir)" "$(DESTDIR)$(stddir)"
LTLIBRARIES = $(noinst_LTLIBRARIES) $(toolexeclib_LTLIBRARIES) LTLIBRARIES = $(noinst_LTLIBRARIES) $(toolexeclib_LTLIBRARIES)
libsupc___la_LIBADD = libsupc___la_LIBADD =
am__objects_1 = array_type_info.lo atexit_arm.lo bad_alloc.lo \ am__objects_1 = array_type_info.lo atexit_arm.lo bad_alloc.lo \
...@@ -122,7 +122,7 @@ CXXCOMPILE = $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \ ...@@ -122,7 +122,7 @@ CXXCOMPILE = $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
$(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS)
CXXLD = $(CXX) CXXLD = $(CXX)
SOURCES = $(libsupc___la_SOURCES) $(libsupc__convenience_la_SOURCES) SOURCES = $(libsupc___la_SOURCES) $(libsupc__convenience_la_SOURCES)
HEADERS = $(glibcxxinstall_HEADERS) HEADERS = $(bits_HEADERS) $(std_HEADERS)
ETAGS = etags ETAGS = etags
CTAGS = ctags CTAGS = ctags
ABI_TWEAKS_SRCDIR = @ABI_TWEAKS_SRCDIR@ ABI_TWEAKS_SRCDIR = @ABI_TWEAKS_SRCDIR@
...@@ -339,10 +339,14 @@ AM_CPPFLAGS = $(GLIBCXX_INCLUDES) ...@@ -339,10 +339,14 @@ AM_CPPFLAGS = $(GLIBCXX_INCLUDES)
toolexeclib_LTLIBRARIES = libsupc++.la toolexeclib_LTLIBRARIES = libsupc++.la
# 2) integrated libsupc++convenience.la that is to be a part of libstdc++.a # 2) integrated libsupc++convenience.la that is to be a part of libstdc++.a
noinst_LTLIBRARIES = libsupc++convenience.la noinst_LTLIBRARIES = libsupc++convenience.la
headers = \ std_HEADERS = \
exception new typeinfo cxxabi.h cxxabi-forced.h exception_defines.h \ cxxabi.h exception initializer_list new typeinfo
initializer_list exception_ptr.h nested_exception.h
bits_HEADERS = \
cxxabi_forced.h hash_bytes.h \
exception_defines.h exception_ptr.h nested_exception.h
headers = $(std_HEADERS) $(bits_HEADERS)
@GLIBCXX_HOSTED_TRUE@c_sources = \ @GLIBCXX_HOSTED_TRUE@c_sources = \
@GLIBCXX_HOSTED_TRUE@ cp-demangle.c @GLIBCXX_HOSTED_TRUE@ cp-demangle.c
...@@ -393,10 +397,8 @@ sources = \ ...@@ -393,10 +397,8 @@ sources = \
vmi_class_type_info.cc \ vmi_class_type_info.cc \
vterminate.cc vterminate.cc
libsupc___la_SOURCES = $(sources) $(c_sources) libsupc___la_SOURCES = $(sources) $(c_sources)
libsupc__convenience_la_SOURCES = $(sources) $(c_sources) libsupc__convenience_la_SOURCES = $(sources) $(c_sources)
glibcxxinstalldir = $(gxx_include_dir)
glibcxxinstall_HEADERS = $(headers)
# AM_CXXFLAGS needs to be in each subdirectory so that it can be # AM_CXXFLAGS needs to be in each subdirectory so that it can be
# modified in a per-library or per-sub-library way. Need to manually # modified in a per-library or per-sub-library way. Need to manually
...@@ -429,7 +431,7 @@ LTCOMPILE = $(LIBTOOL) --tag CC --tag disable-shared $(LIBTOOLFLAGS) --mode=comp ...@@ -429,7 +431,7 @@ LTCOMPILE = $(LIBTOOL) --tag CC --tag disable-shared $(LIBTOOLFLAGS) --mode=comp
$(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
# libstdc++ libtool notes # Libtool notes
# 1) Need to explicitly set LTCXXCOMPILE so that AM_CXXFLAGS is # 1) Need to explicitly set LTCXXCOMPILE so that AM_CXXFLAGS is
# last. (That way, things like -O2 passed down from the toplevel can # last. (That way, things like -O2 passed down from the toplevel can
...@@ -466,6 +468,12 @@ CXXLINK = $(LIBTOOL) --tag CXX --tag disable-shared $(LIBTOOLFLAGS) \ ...@@ -466,6 +468,12 @@ CXXLINK = $(LIBTOOL) --tag CXX --tag disable-shared $(LIBTOOLFLAGS) \
--mode=link $(CXX) \ --mode=link $(CXX) \
$(OPT_LDFLAGS) $(SECTION_LDFLAGS) $(AM_CXXFLAGS) $(LTLDFLAGS) -o $@ $(OPT_LDFLAGS) $(SECTION_LDFLAGS) $(AM_CXXFLAGS) $(LTLDFLAGS) -o $@
# Install notes
# We have to have rules modified from the default to counteract SUN make
# prepending each of $(*_HEADERS) with VPATH below.
stddir = $(gxx_include_dir)
bitsdir = $(gxx_include_dir)/bits
all: all-am all: all-am
.SUFFIXES: .SUFFIXES:
...@@ -630,7 +638,7 @@ check-am: all-am ...@@ -630,7 +638,7 @@ check-am: all-am
check: check-am check: check-am
all-am: Makefile $(LTLIBRARIES) $(HEADERS) all-am: Makefile $(LTLIBRARIES) $(HEADERS)
installdirs: installdirs:
for dir in "$(DESTDIR)$(toolexeclibdir)" "$(DESTDIR)$(glibcxxinstalldir)"; do \ for dir in "$(DESTDIR)$(toolexeclibdir)" "$(DESTDIR)$(bitsdir)" "$(DESTDIR)$(stddir)"; do \
test -z "$$dir" || $(MKDIR_P) "$$dir"; \ test -z "$$dir" || $(MKDIR_P) "$$dir"; \
done done
install: install-am install: install-am
...@@ -680,7 +688,7 @@ info: info-am ...@@ -680,7 +688,7 @@ info: info-am
info-am: info-am:
install-data-am: install-glibcxxinstallHEADERS install-data-am: install-bitsHEADERS install-stdHEADERS
install-dvi: install-dvi-am install-dvi: install-dvi-am
...@@ -725,7 +733,7 @@ ps: ps-am ...@@ -725,7 +733,7 @@ ps: ps-am
ps-am: ps-am:
uninstall-am: uninstall-glibcxxinstallHEADERS \ uninstall-am: uninstall-bitsHEADERS uninstall-stdHEADERS \
uninstall-toolexeclibLTLIBRARIES uninstall-toolexeclibLTLIBRARIES
.MAKE: install-am install-strip .MAKE: install-am install-strip
...@@ -734,16 +742,17 @@ uninstall-am: uninstall-glibcxxinstallHEADERS \ ...@@ -734,16 +742,17 @@ uninstall-am: uninstall-glibcxxinstallHEADERS \
clean-libtool clean-noinstLTLIBRARIES \ clean-libtool clean-noinstLTLIBRARIES \
clean-toolexeclibLTLIBRARIES ctags distclean distclean-compile \ clean-toolexeclibLTLIBRARIES ctags distclean distclean-compile \
distclean-generic distclean-libtool distclean-tags dvi dvi-am \ distclean-generic distclean-libtool distclean-tags dvi dvi-am \
html html-am info info-am install install-am install-data \ html html-am info info-am install install-am \
install-data-am install-dvi install-dvi-am install-exec \ install-bitsHEADERS install-data install-data-am install-dvi \
install-exec-am install-glibcxxinstallHEADERS install-html \ install-dvi-am install-exec install-exec-am install-html \
install-html-am install-info install-info-am install-man \ install-html-am install-info install-info-am install-man \
install-pdf install-pdf-am install-ps install-ps-am \ install-pdf install-pdf-am install-ps install-ps-am \
install-strip install-toolexeclibLTLIBRARIES installcheck \ install-stdHEADERS install-strip \
installcheck-am installdirs maintainer-clean \ install-toolexeclibLTLIBRARIES installcheck installcheck-am \
maintainer-clean-generic mostlyclean mostlyclean-compile \ installdirs maintainer-clean maintainer-clean-generic \
mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ mostlyclean mostlyclean-compile mostlyclean-generic \
tags uninstall uninstall-am uninstall-glibcxxinstallHEADERS \ mostlyclean-libtool pdf pdf-am ps ps-am tags uninstall \
uninstall-am uninstall-bitsHEADERS uninstall-stdHEADERS \
uninstall-toolexeclibLTLIBRARIES uninstall-toolexeclibLTLIBRARIES
...@@ -755,23 +764,38 @@ cp-demangle.lo: cp-demangle.c ...@@ -755,23 +764,38 @@ cp-demangle.lo: cp-demangle.c
cp-demangle.o: cp-demangle.c cp-demangle.o: cp-demangle.c
$(C_COMPILE) -DIN_GLIBCPP_V3 -Wno-error -c $< $(C_COMPILE) -DIN_GLIBCPP_V3 -Wno-error -c $<
# We have to have rules modified from the default to counteract SUN make install-stdHEADERS: $(std_HEADERS)
# prepending each of $(glibcxxinstall_HEADERS) with VPATH below.
install-glibcxxinstallHEADERS: $(glibcxxinstall_HEADERS)
@$(NORMAL_INSTALL) @$(NORMAL_INSTALL)
$(mkinstalldirs) $(DESTDIR)$(glibcxxinstalldir) $(mkinstalldirs) $(DESTDIR)$(stddir)
@list='$(glibcxxinstall_HEADERS)'; for p in $$list; do \ @list='$(std_HEADERS)'; for p in $$list; do \
q=`echo $$p | sed -e 's,.*/,,'`; \ q=`echo $$p | sed -e 's,.*/,,'`; \
if test -f "$$p"; then d= ; else d="$(srcdir)/"; fi; \ if test -f "$$p"; then d= ; else d="$(srcdir)/"; fi; \
echo " $(INSTALL_DATA) $$d$$p $(DESTDIR)$(glibcxxinstalldir)/$$q"; \ echo " $(INSTALL_DATA) $$d$$p $(DESTDIR)$(stddir)/$$q"; \
$(INSTALL_DATA) $$d$$p $(DESTDIR)$(glibcxxinstalldir)/$$q; \ $(INSTALL_DATA) $$d$$p $(DESTDIR)$(stddir)/$$q; \
done
install-bitsHEADERS: $(bits_HEADERS)
@$(NORMAL_INSTALL)
$(mkinstalldirs) $(DESTDIR)$(bitsdir)
@list='$(bits_HEADERS)'; for p in $$list; do \
q=`echo $$p | sed -e 's,.*/,,'`; \
if test -f "$$p"; then d= ; else d="$(srcdir)/"; fi; \
echo " $(INSTALL_DATA) $$d$$p $(DESTDIR)$(bitsdir)/$$q"; \
$(INSTALL_DATA) $$d$$p $(DESTDIR)$(bitsdir)/$$q; \
done
uninstall-stdHEADERS:
@$(NORMAL_UNINSTALL)
list='$(std_HEADERS)'; for p in $$list; do \
q=`echo $$p | sed -e 's,.*/,,'`; \
rm -f $(DESTDIR)$(stddir)/$$q; \
done done
uninstall-glibcxxinstallHEADERS: uninstall-bitsHEADERS:
@$(NORMAL_UNINSTALL) @$(NORMAL_UNINSTALL)
list='$(glibcxxinstall_HEADERS)'; for p in $$list; do \ list='$(bits_HEADERS)'; for p in $$list; do \
q=`echo $$p | sed -e 's,.*/,,'`; \ q=`echo $$p | sed -e 's,.*/,,'`; \
rm -f $(DESTDIR)$(glibcxxinstalldir)/$$q; \ rm -f $(DESTDIR)$(bitsdir)/$$q; \
done done
# Tell versions [3.59,3.63) of GNU make to not export all variables. # Tell versions [3.59,3.63) of GNU make to not export all variables.
......
// cxxabi.h subset for inclusion by other library headers -*- C++ -*- // cxxabi.h subset for cancellation -*- C++ -*-
// Copyright (C) 2007, 2009, 2010 Free Software Foundation, Inc. // Copyright (C) 2007, 2009, 2010, 2011 Free Software Foundation, Inc.
// //
// This file is part of GCC. // This file is part of GCC.
// //
...@@ -23,8 +23,9 @@ ...@@ -23,8 +23,9 @@
// see the files COPYING3 and COPYING.RUNTIME respectively. If not, see // see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
// <http://www.gnu.org/licenses/>. // <http://www.gnu.org/licenses/>.
/** @file cxxabi-forced.h /** @file bits/cxxabi_forced.h
* The header provides an interface to the C++ ABI. * This is an internal header file, included by other library headers.
* Do not attempt to use it directly. @headername{cxxabi.h}
*/ */
#ifndef _CXXABI_FORCED_H #ifndef _CXXABI_FORCED_H
......
// -*- C++ -*- Common throw conditions. // -*- C++ -*- Common throw conditions.
// Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2009 // Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2009, 2011
// Free Software Foundation // Free Software Foundation
// //
// This file is part of GCC. // This file is part of GCC.
...@@ -27,7 +27,7 @@ ...@@ -27,7 +27,7 @@
#include "exception" #include "exception"
#include <cstdlib> #include <cstdlib>
#include "unwind-cxx.h" #include "unwind-cxx.h"
#include "exception_defines.h" #include <bits/exception_defines.h>
extern "C" void extern "C" void
__cxxabiv1::__cxa_bad_cast () __cxxabiv1::__cxa_bad_cast ()
......
// -*- C++ -*- Helpers for calling unextected and terminate // -*- C++ -*- Helpers for calling unextected and terminate
// Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 // Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009,
// 2011
// Free Software Foundation, Inc. // Free Software Foundation, Inc.
// //
// This file is part of GCC. // This file is part of GCC.
...@@ -25,7 +26,7 @@ ...@@ -25,7 +26,7 @@
#include <bits/c++config.h> #include <bits/c++config.h>
#include <cstdlib> #include <cstdlib>
#include <exception_defines.h> #include <bits/exception_defines.h>
#include "unwind-cxx.h" #include "unwind-cxx.h"
using namespace __cxxabiv1; using namespace __cxxabiv1;
......
// -*- C++ -*- The GNU C++ exception personality routine. // -*- C++ -*- The GNU C++ exception personality routine.
// Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 // Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010,
// 2011
// Free Software Foundation, Inc. // Free Software Foundation, Inc.
// //
// This file is part of GCC. // This file is part of GCC.
...@@ -25,7 +26,7 @@ ...@@ -25,7 +26,7 @@
#include <bits/c++config.h> #include <bits/c++config.h>
#include <cstdlib> #include <cstdlib>
#include <exception_defines.h> #include <bits/exception_defines.h>
#include <cxxabi.h> #include <cxxabi.h>
#include "unwind-cxx.h" #include "unwind-cxx.h"
......
...@@ -29,7 +29,7 @@ ...@@ -29,7 +29,7 @@
#define _GLIBCXX_EH_PTR_COMPAT #define _GLIBCXX_EH_PTR_COMPAT
#include <exception> #include <exception>
#include <exception_ptr.h> #include <bits/exception_ptr.h>
#include "unwind-cxx.h" #include "unwind-cxx.h"
using namespace __cxxabiv1; using namespace __cxxabiv1;
......
// -*- C++ -*- std::terminate, std::unexpected and friends. // -*- C++ -*- std::terminate, std::unexpected and friends.
// Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2009 // Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2009,
// 2011
// Free Software Foundation // Free Software Foundation
// //
// This file is part of GCC. // This file is part of GCC.
...@@ -27,7 +28,7 @@ ...@@ -27,7 +28,7 @@
#include "exception" #include "exception"
#include <cstdlib> #include <cstdlib>
#include "unwind-cxx.h" #include "unwind-cxx.h"
#include "exception_defines.h" #include <bits/exception_defines.h>
using namespace __cxxabiv1; using namespace __cxxabiv1;
......
// Exception Handling support header for -*- C++ -*- // Exception Handling support header for -*- C++ -*-
// Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, // Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003,
// 2004, 2005, 2006, 2007, 2008, 2009, 2010 // 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011
// Free Software Foundation // Free Software Foundation
// //
// This file is part of GCC. // This file is part of GCC.
...@@ -148,8 +148,8 @@ _GLIBCXX_END_NAMESPACE ...@@ -148,8 +148,8 @@ _GLIBCXX_END_NAMESPACE
#if (defined(__GXX_EXPERIMENTAL_CXX0X__) \ #if (defined(__GXX_EXPERIMENTAL_CXX0X__) \
&& defined(_GLIBCXX_ATOMIC_BUILTINS_4)) && defined(_GLIBCXX_ATOMIC_BUILTINS_4))
#include <exception_ptr.h> #include <bits/exception_ptr.h>
#include <nested_exception.h> #include <bits/nested_exception.h>
#endif #endif
#endif #endif
// -fno-exceptions Support -*- C++ -*- // -fno-exceptions Support -*- C++ -*-
// Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006, 2006, 2007, 2008, 2009 // Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006, 2006, 2007, 2008, 2009,
// 2011
// Free Software Foundation, Inc. // Free Software Foundation, Inc.
// //
// This file is part of the GNU ISO C++ Library. This library is free // This file is part of the GNU ISO C++ Library. This library is free
...@@ -23,12 +24,9 @@ ...@@ -23,12 +24,9 @@
// see the files COPYING3 and COPYING.RUNTIME respectively. If not, see // see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
// <http://www.gnu.org/licenses/>. // <http://www.gnu.org/licenses/>.
// /** @file bits/exception_defines.h
// ISO C++ 14882: 19.1 Exception classes * This is an internal header file, included by other library headers.
// * Do not attempt to use it directly. @headername{exception}
/** @file exception_defines.h
* This is a Standard C++ Library header.
*/ */
#ifndef _EXCEPTION_DEFINES_H #ifndef _EXCEPTION_DEFINES_H
......
// Exception Handling support header (exception_ptr class) for -*- C++ -*- // Exception Handling support header (exception_ptr class) for -*- C++ -*-
// Copyright (C) 2008, 2009, 2010 Free Software Foundation // Copyright (C) 2008, 2009, 2010, 2011 Free Software Foundation
// //
// This file is part of GCC. // This file is part of GCC.
// //
...@@ -23,7 +23,7 @@ ...@@ -23,7 +23,7 @@
// see the files COPYING3 and COPYING.RUNTIME respectively. If not, see // see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
// <http://www.gnu.org/licenses/>. // <http://www.gnu.org/licenses/>.
/** @file exception_ptr.h /** @file bits/exception_ptr.h
* This is an internal header file, included by other library headers. * This is an internal header file, included by other library headers.
* Do not attempt to use it directly. @headername{exception} * Do not attempt to use it directly. @headername{exception}
*/ */
...@@ -34,7 +34,7 @@ ...@@ -34,7 +34,7 @@
#pragma GCC visibility push(default) #pragma GCC visibility push(default)
#include <bits/c++config.h> #include <bits/c++config.h>
#include <exception_defines.h> #include <bits/exception_defines.h>
#if !defined(_GLIBCXX_ATOMIC_BUILTINS_4) #if !defined(_GLIBCXX_ATOMIC_BUILTINS_4)
# error This platform does not support exception propagation. # error This platform does not support exception propagation.
......
// Definition of _Hash_bytes. -*- C++ -*- // Definition of _Hash_bytes. -*- C++ -*-
// Copyright (C) 2010 Free Software Foundation, Inc. // Copyright (C) 2010, 2011 Free Software Foundation, Inc.
// //
// This file is part of the GNU ISO C++ Library. This library is free // 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 // software; you can redistribute it and/or modify it under the
...@@ -32,7 +32,7 @@ ...@@ -32,7 +32,7 @@
// function apears to be better in both speed and hash quality, and // function apears to be better in both speed and hash quality, and
// FNV is provided primarily for backward compatibility. // FNV is provided primarily for backward compatibility.
#include <bits/c++config.h> #include <bits/hash_bytes.h>
namespace namespace
{ {
...@@ -63,8 +63,8 @@ namespace ...@@ -63,8 +63,8 @@ namespace
#endif #endif
} }
namespace std _GLIBCXX_BEGIN_NAMESPACE(std)
{
#if __SIZEOF_SIZE_T__ == 4 #if __SIZEOF_SIZE_T__ == 4
// Implementation of Murmur hash for 32-bit size_t. // Implementation of Murmur hash for 32-bit size_t.
...@@ -97,7 +97,7 @@ namespace std ...@@ -97,7 +97,7 @@ namespace std
hash ^= static_cast<unsigned char>(buf[1]) << 8; hash ^= static_cast<unsigned char>(buf[1]) << 8;
case 1: case 1:
hash ^= static_cast<unsigned char>(buf[0]); hash ^= static_cast<unsigned char>(buf[0]);
hash *= m; hash *= m;
}; };
// Do a few final mixes of the hash. // Do a few final mixes of the hash.
...@@ -182,4 +182,5 @@ namespace std ...@@ -182,4 +182,5 @@ namespace std
{ return _Hash_bytes(ptr, len, seed); } { return _Hash_bytes(ptr, len, seed); }
#endif /* __SIZEOF_SIZE_T__ */ #endif /* __SIZEOF_SIZE_T__ */
}
_GLIBCXX_END_NAMESPACE
// Declarations for hash functions. -*- C++ -*-
// Copyright (C) 2010, 2011 Free Software Foundation, Inc.
//
// This file is part of the GNU ISO C++ Library. This library is free
// software; you can redistribute it and/or modify it under the
// terms of the GNU General Public License as published by the
// Free Software Foundation; either version 3, or (at your option)
// any later version.
// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
// 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/>.
/** @file bits/hash_bytes.h
* This is an internal header file, included by other library headers.
* Do not attempt to use it directly. @headername{functional}
*/
#ifndef _HASH_BYTES_H
#define _HASH_BYTES_H 1
#pragma GCC system_header
#include <bits/c++config.h>
_GLIBCXX_BEGIN_NAMESPACE(std)
// Hash function implementation for the nontrivial specialization.
// All of them are based on a primitive that hashes a pointer to a
// byte array. The actual hash algorithm is not guaranteed to stay
// the same from release to release -- it may be updated or tuned to
// improve hash quality or speed.
size_t
_Hash_bytes(const void* __ptr, size_t __len, size_t __seed);
// A similar hash primitive, using the FNV hash algorithm. This
// algorithm is guaranteed to stay the same from release to release.
// (although it might not produce the same values on different
// machines.)
size_t
_Fnv_hash_bytes(const void* __ptr, size_t __len, size_t __seed);
_GLIBCXX_END_NAMESPACE
#endif
// Nested Exception support header (nested_exception class) for -*- C++ -*- // Nested Exception support header (nested_exception class) for -*- C++ -*-
// Copyright (C) 2009, 2010 Free Software Foundation, Inc. // Copyright (C) 2009, 2010, 2011 Free Software Foundation, Inc.
// //
// This file is part of the GNU ISO C++ Library. This library is free // 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 // software; you can redistribute it and/or modify it under the
...@@ -22,7 +22,7 @@ ...@@ -22,7 +22,7 @@
// see the files COPYING3 and COPYING.RUNTIME respectively. If not, see // see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
// <http://www.gnu.org/licenses/>. // <http://www.gnu.org/licenses/>.
/** @file nested_exception.h /** @file bits/nested_exception.h
* This is an internal header file, included by other library headers. * This is an internal header file, included by other library headers.
* Do not attempt to use it directly. @headername{exception} * Do not attempt to use it directly. @headername{exception}
*/ */
......
// Support routines for the -*- C++ -*- dynamic memory management. // Support routines for the -*- C++ -*- dynamic memory management.
// Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2004, 2009 // Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2004, 2009, 2011
// Free Software Foundation // Free Software Foundation
// //
// This file is part of GCC. // This file is part of GCC.
...@@ -26,7 +26,7 @@ ...@@ -26,7 +26,7 @@
#include <bits/c++config.h> #include <bits/c++config.h>
#include <cstdlib> #include <cstdlib>
#include <exception_defines.h> #include <bits/exception_defines.h>
#include "new" #include "new"
using std::new_handler; using std::new_handler;
......
// Support routines for the -*- C++ -*- dynamic memory management. // Support routines for the -*- C++ -*- dynamic memory management.
// Copyright (C) 1997, 1998, 1999, 2000, 2001, 2004, 2009 // Copyright (C) 1997, 1998, 1999, 2000, 2001, 2004, 2009, 2011
// Free Software Foundation // Free Software Foundation
// //
// This file is part of GCC. // This file is part of GCC.
...@@ -24,7 +24,7 @@ ...@@ -24,7 +24,7 @@
// <http://www.gnu.org/licenses/>. // <http://www.gnu.org/licenses/>.
#include <bits/c++config.h> #include <bits/c++config.h>
#include <exception_defines.h> #include <bits/exception_defines.h>
#include "new" #include "new"
using std::new_handler; using std::new_handler;
......
// RTTI support for -*- C++ -*- // RTTI support for -*- C++ -*-
// Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, // Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
// 2003, 2004, 2005, 2006, 2007, 2009, 2010 // 2003, 2004, 2005, 2006, 2007, 2009, 2010, 2011
// Free Software Foundation // Free Software Foundation
// //
// This file is part of GCC. // This file is part of GCC.
...@@ -34,6 +34,10 @@ ...@@ -34,6 +34,10 @@
#pragma GCC system_header #pragma GCC system_header
#include <exception> #include <exception>
#ifdef __GXX_EXPERIMENTAL_CXX0X__
#include <bits/hash_bytes.h>
#endif
#pragma GCC visibility push(default) #pragma GCC visibility push(default)
...@@ -78,11 +82,6 @@ namespace __cxxabiv1 ...@@ -78,11 +82,6 @@ namespace __cxxabiv1
namespace std namespace std
{ {
#ifdef __GXX_EXPERIMENTAL_CXX0X__
size_t
_Hash_bytes(const void* __ptr, size_t __len, size_t __seed);
#endif
/** /**
* @brief Part of RTTI. * @brief Part of RTTI.
* *
......
// New abi Support -*- C++ -*- // New abi Support -*- C++ -*-
// Copyright (C) 2000, 2001, 2003, 2004, 2009 Free Software Foundation, Inc. // Copyright (C) 2000, 2001, 2003, 2004, 2009, 2011
// Free Software Foundation, Inc.
// //
// This file is part of GCC. // This file is part of GCC.
// //
...@@ -28,7 +29,7 @@ ...@@ -28,7 +29,7 @@
#include <cxxabi.h> #include <cxxabi.h>
#include <new> #include <new>
#include <exception> #include <exception>
#include <exception_defines.h> #include <bits/exception_defines.h>
#include "unwind-cxx.h" #include "unwind-cxx.h"
namespace __cxxabiv1 namespace __cxxabiv1
......
// Verbose terminate_handler -*- C++ -*- // Verbose terminate_handler -*- C++ -*-
// Copyright (C) 2001, 2002, 2004, 2005, 2009 Free Software Foundation // Copyright (C) 2001, 2002, 2004, 2005, 2009, 2011 Free Software Foundation
// //
// This file is part of the GNU ISO C++ Library. This library is free // 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 // software; you can redistribute it and/or modify it under the
...@@ -27,7 +27,7 @@ ...@@ -27,7 +27,7 @@
#if _GLIBCXX_HOSTED #if _GLIBCXX_HOSTED
#include <cstdlib> #include <cstdlib>
#include <exception> #include <exception>
#include <exception_defines.h> #include <bits/exception_defines.h>
#include <cxxabi.h> #include <cxxabi.h>
# include <cstdio> # include <cstdio>
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
// -*- C++ -*- // -*- C++ -*-
// Copyright (C) 2006, 2007, 2009, 2010 Free Software Foundation, Inc. // Copyright (C) 2006, 2007, 2009, 2010, 2011 Free Software Foundation, Inc.
// //
// This file is part of the GNU ISO C++ Library. This library is free // 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 // software; you can redistribute it and/or modify it under the
...@@ -22,4 +22,4 @@ ...@@ -22,4 +22,4 @@
#include <vector> #include <vector>
// { dg-error "Cannot use -D_GLIBCXX_PROFILE with " "" { target *-*-* } 223 } // { dg-error "Cannot use -D_GLIBCXX_PROFILE with " "" { target *-*-* } 220 }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment