gcc/libstdc++-v3/testsuite/27_io
Jonathan Wakely b02923592a Add support for opening file streams from wide character strings
C++17 added new overloads to <fstream> class templates to support
opening files from wide character strings "on systems where
filesystem::path::value_type is not char". This patch adds those
overloads conditional on _wfopen being available, and enables them for
pre-C++17 modes as well.

	Add support for opening file streams from wide character strings.
	* config/io/basic_file_stdio.cc [_GLIBCXX_HAVE__WFOPEN]
	(__basic_file<char>::open(const wchar_t*, ios_base::openmode)):
	Define new overload.
	* config/io/basic_file_stdio.h [_GLIBCXX_HAVE__WFOPEN]
	(__basic_file<char>::open(const wchar_t*, ios_base::openmode)):
	Declare new overload.
	* configure.ac: Check for _wfopen.
	* crossconfig.m4: Likewise.
	* configure: Regenerate.
	* config.h.in: Regenerate.
	* include/bits/fstream.tcc [_GLIBCXX_HAVE__WFOPEN]
	(basic_filebuf<C,T>::open(const wchar_t*, ios_base::openmode)):
	Define new overload.
	* include/std/fstream [_GLIBCXX_HAVE__WFOPEN]
	(basic_filebuf<C,T>::open(const wchar_t*, ios_base::openmode)):
	Declare new overload.
	[_GLIBCXX_HAVE__WFOPEN]
	(basic_ifstream<C,T>::basic_ifstream(const wchar_t*, openmode))
	(basic_ifstream<C,T>::basic_open(const wchar_t*, openmode))
	(basic_ofstream<C,T>::basic_ifstream(const wchar_t*, openmode))
	(basic_ofstream<C,T>::basic_open(const wchar_t*, openmode))
	(basic_fstream<C,T>::basic_ifstream(const wchar_t*, openmode))
	(basic_fstream<C,T>::basic_open(const wchar_t*, openmode)): Define
	new overloads.
	* testsuite/27_io/basic_filebuf/open/wchar_t/1.cc: New.
	* testsuite/27_io/basic_ifstream/cons/wchar_t/1.cc: New.
	* testsuite/27_io/basic_ifstream/open/wchar_t/1.cc: New.
	* testsuite/27_io/basic_ofstream/cons/wchar_t/1.cc: New.
	* testsuite/27_io/basic_ofstream/open/wchar_t/1.cc: New.
	* testsuite/27_io/basic_fstream/cons/wchar_t/1.cc: New.
	* testsuite/27_io/basic_fstream/open/wchar_t/1.cc: New.

From-SVN: r260479
2018-05-21 18:18:35 +01:00
..
basic_filebuf Add support for opening file streams from wide character strings 2018-05-21 18:18:35 +01:00
basic_fstream Add support for opening file streams from wide character strings 2018-05-21 18:18:35 +01:00
basic_ifstream Add support for opening file streams from wide character strings 2018-05-21 18:18:35 +01:00
basic_ios PR libstdc++/85222 allow catching iostream errors as gcc4-compatible ios::failure 2018-04-10 15:36:09 +01:00
basic_iostream Update copyright years. 2018-01-03 11:03:58 +01:00
basic_istream PR libstdc++/85222 allow catching iostream errors as gcc4-compatible ios::failure 2018-04-10 15:36:09 +01:00
basic_istringstream Update copyright years. 2018-01-03 11:03:58 +01:00
basic_ofstream Add support for opening file streams from wide character strings 2018-05-21 18:18:35 +01:00
basic_ostream PR libstdc++/85222 allow catching iostream errors as gcc4-compatible ios::failure 2018-04-10 15:36:09 +01:00
basic_ostringstream Update copyright years. 2018-01-03 11:03:58 +01:00
basic_streambuf Update copyright years. 2018-01-03 11:03:58 +01:00
basic_stringbuf Update copyright years. 2018-01-03 11:03:58 +01:00
basic_stringstream Update copyright years. 2018-01-03 11:03:58 +01:00
filesystem Fix std::filesystem::absolute for empty paths 2018-05-21 13:52:44 +01:00
fpos Update copyright years. 2018-01-03 11:03:58 +01:00
headers Update copyright years. 2018-01-03 11:03:58 +01:00
ios_base PR libstdc++/68197 fail on negative iword/pword indices 2018-05-02 20:04:55 +01:00
manipulators Update copyright years. 2018-01-03 11:03:58 +01:00
objects Update copyright years. 2018-01-03 11:03:58 +01:00
types Update copyright years. 2018-01-03 11:03:58 +01:00
rvalue_streams-2.cc Update copyright years. 2018-01-03 11:03:58 +01:00
rvalue_streams.cc Update copyright years. 2018-01-03 11:03:58 +01:00