gcc/libstdc++-v3/testsuite/27_io
Jonathan Wakely f997b67550 libstdc++: Add C++11 member functions for ios::failure in old ABI
The new constructors that C++11 added to std::ios_base::failure were
missing for the old ABI. This adds them, but just ignores the
std::error_code argument (because there's nowhere to store it).

This also adds a code() member, which should be provided by the
std::system_error base class, but that base class isn't present in the
old ABI.

This allows the old ios::failure to be used in code that expects the new
API, although with reduced functionality.

libstdc++-v3/ChangeLog:

	* include/bits/ios_base.h (ios_base::failure): Add constructors
	takeing error_code argument. Add code() member function.
	* testsuite/27_io/ios_base/failure/cxx11.cc: Allow test to
	run for the old ABI but do not check for derivation from
	std::system_error.
	* testsuite/27_io/ios_base/failure/error_code.cc: New test.
2020-10-08 14:45:37 +01:00
..
basic_filebuf Update copyright years. 2020-01-01 12:51:42 +01:00
basic_fstream Update copyright years. 2020-01-01 12:51:42 +01:00
basic_ifstream Update copyright years. 2020-01-01 12:51:42 +01:00
basic_ios libstdc++: Require c++98_only effective target for a test 2020-07-02 21:27:22 +01:00
basic_iostream Update copyright years. 2020-01-01 12:51:42 +01:00
basic_istream libstdc++: Do not set eofbit eagerly in operator>>(istream&, char(&)[N]) 2020-08-06 19:23:14 +01:00
basic_istringstream Update copyright years. 2020-01-01 12:51:42 +01:00
basic_ofstream Update copyright years. 2020-01-01 12:51:42 +01:00
basic_ostream libstdc++: Ensure c++NN effective target present in all C++17 tests 2020-07-31 19:58:02 +01:00
basic_ostringstream Update copyright years. 2020-01-01 12:51:42 +01:00
basic_streambuf Update copyright years. 2020-01-01 12:51:42 +01:00
basic_stringbuf Update copyright years. 2020-01-01 12:51:42 +01:00
basic_stringstream Update copyright years. 2020-01-01 12:51:42 +01:00
filesystem libstdc++: Fix out-of-bounds string_view access in filesystem::path [PR 97167] 2020-09-22 20:02:58 +01:00
fpos tolerate padding in mbstate_t 2020-01-23 16:36:34 -03:00
headers libstdc++: Require c++98_only effective target for some tests 2020-07-02 21:27:12 +01:00
ios_base libstdc++: Add C++11 member functions for ios::failure in old ABI 2020-10-08 14:45:37 +01:00
manipulators Update copyright years. 2020-01-01 12:51:42 +01:00
objects Update copyright years. 2020-01-01 12:51:42 +01:00
types libstdc++: Add deprecated attributes to old iostream members 2020-08-19 12:13:23 +01:00
rvalue_streams-2.cc Update copyright years. 2020-01-01 12:51:42 +01:00
rvalue_streams.cc Update copyright years. 2020-01-01 12:51:42 +01:00