gcc/libstdc++-v3
Jonathan Wakely 50c2df93a6 PR libstdc++/51333 Define recursive_init_error constructor non-inline
The recursive_init_error class is defined in a header, with an inline
constructor, but the definition of the vtable and destructor are not
exported from the shared library. With -fkeep-inline-functions the
constructor gets emitted in user code, and requires the (non-exported)
vtable. This fails to link.

As far as I can tell, the recursive_init_error class definition was
moved into <cxxabi.h> so it could be documented with Doxygen, not for
any technical reason. But now it's there (and documented), somebody
could be relying on it, by catching that type and possibly performing
derived-to-base conversions to the std::exception base class. So the
conservative fix is to leave the class definition in the header but make
the constructor non-inline. This still allows the type to be caught and
still defines its base class. User code can no longer construct objects
of that type, but that's not something we need to support.

	PR libstdc++/51333
	* libsupc++/cxxabi.h (__gnu_cxx::recursive_init_error): Do not define
	constructor inline.
	* libsupc++/guard_error.cc (__gnu_cxx::recursive_init_error): Define
	constructor.
	* testsuite/18_support/51333.cc: New test.

From-SVN: r273878
2019-07-29 15:27:19 +01:00
..
config * config/abi/post/m68k-linux-gnu/baseline_symbols.txt: Update. 2019-07-19 09:57:08 +00:00
doc documentation_hacking.xml: Fix broken reference to the Doxygen manual. 2019-07-28 09:10:32 +00:00
include Define __cpp_lib_endian feature test macro 2019-07-26 14:30:42 +01:00
libsupc++ PR libstdc++/51333 Define recursive_init_error constructor non-inline 2019-07-29 15:27:19 +01:00
po
python Have std::vector printer's iterator return bool for vector<bool> 2019-06-19 23:57:06 +01:00
scripts Remove Profile Mode, deprecated since GCC 7.1 2019-05-13 11:50:21 +01:00
src PR libstdc++/91012 fixfilesystem_error::what() string 2019-06-27 10:42:39 +01:00
testsuite PR libstdc++/51333 Define recursive_init_error constructor non-inline 2019-07-29 15:27:19 +01:00
ChangeLog PR libstdc++/51333 Define recursive_init_error constructor non-inline 2019-07-29 15:27:19 +01:00
ChangeLog-1998
ChangeLog-1999
ChangeLog-2000
ChangeLog-2001
ChangeLog-2002
ChangeLog-2003
ChangeLog-2004
ChangeLog-2005
ChangeLog-2006
ChangeLog-2007
ChangeLog-2008
ChangeLog-2009
ChangeLog-2010
ChangeLog-2011
ChangeLog-2012
ChangeLog-2013
ChangeLog-2014
ChangeLog-2015
ChangeLog-2016
ChangeLog-2017
ChangeLog-2018
Makefile.am
Makefile.in
README
acinclude.m4 PR libstdc++/91067 fix missing exports for filesystem iterators 2019-07-03 22:06:25 +01:00
aclocal.m4
config.h.in PR libstdc++/85494 use rdseed and rand_s in std::random_device 2019-05-29 15:45:35 +01:00
configure PR libstdc++/91067 fix missing exports for filesystem iterators 2019-07-03 22:06:25 +01:00
configure.ac Fix libstdc++ install-pdf support. 2019-07-01 19:30:52 -07:00
configure.host Remove obsolete Solaris 10 support 2019-05-14 17:17:23 +00:00
crossconfig.m4
fragment.am
linkage.m4

README

file: libstdc++-v3/README

New users may wish to point their web browsers to the file
index.html in the 'doc/html' subdirectory.  It contains brief
building instructions and notes on how to configure the library in
interesting ways.