gcc/libstdc++-v3/testsuite/libstdc++-prettyprinters
Jonathan Wakely 91e6226f88 libstdc++: Remove inheritance from elements in std::tuple
This fixes a number of std::tuple bugs by no longer making use of the
empty base-class optimization. By using the C++20 [[no_unique_address]]
attribute we can always store the element as a data member, while still
compressing the layout of tuples containing empty types.

Since we no longer use inheritance we could also apply the compression
optimization for final types and for tuples of tuples, but doing so
would be an ABI break.

Using [[no_unique_address]] more liberally for the unstable std::__8
configuration is left for a later date. There may be reasons not to
apply the attribute unconditionally, e.g. see the discussion about
guaranteed elision in PR 94062.

libstdc++-v3/ChangeLog:

	PR libstdc++/55713
	PR libstdc++/71096
	PR libstdc++/93147
	* include/std/tuple [__has_cpp_attribute(no_unique_address)]
	(_Head_base<Idx, Head, true>): New definition of the partial
	specialization, using [[no_unique_address]] instead of
	inheritance.
	* testsuite/libstdc++-prettyprinters/48362.cc: Adjust expected
	output.
	* testsuite/20_util/tuple/comparison_operators/93147.cc: New test.
	* testsuite/20_util/tuple/creation_functions/55713.cc: New test.
	* testsuite/20_util/tuple/element_access/71096.cc: New test.
2020-08-17 15:27:51 +01:00
..
48362.cc libstdc++: Remove inheritance from elements in std::tuple 2020-08-17 15:27:51 +01:00
59161.cc Update copyright years. 2020-01-01 12:51:42 +01:00
80276.cc Update copyright years. 2020-01-01 12:51:42 +01:00
91997.cc Update copyright years. 2020-01-01 12:51:42 +01:00
compat.cc libstdc++: Fix compatibility support in unique_ptr pretty printer 2020-08-10 18:47:06 +01:00
cxx11.cc Update copyright years. 2020-01-01 12:51:42 +01:00
cxx17.cc Update copyright years. 2020-01-01 12:51:42 +01:00
cxx20.cc Update copyright years. 2020-01-01 12:51:42 +01:00
debug_cxx11.cc Update copyright years. 2020-01-01 12:51:42 +01:00
debug.cc Update copyright years. 2020-01-01 12:51:42 +01:00
libfundts.cc Update copyright years. 2020-01-01 12:51:42 +01:00
prettyprinters.exp Update copyright years. 2020-01-01 12:51:42 +01:00
shared_ptr.cc Update copyright years. 2020-01-01 12:51:42 +01:00
simple11.cc Update copyright years. 2020-01-01 12:51:42 +01:00
simple.cc Update copyright years. 2020-01-01 12:51:42 +01:00
tr1.cc Update copyright years. 2020-01-01 12:51:42 +01:00
whatis2.cc Update copyright years. 2020-01-01 12:51:42 +01:00
whatis.cc Update copyright years. 2020-01-01 12:51:42 +01:00