Skip to content

Commit

Permalink
PR libstdc++/82917 add missing returns in <fstream>
Browse files Browse the repository at this point in the history
	PR libstdc++/82917
	* include/std/fstream (basic_ifstream::open, basic_ofstream::open)
	(basic_fstream::open): Fix missing return.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@254638 138bc75d-0d04-0410-961f-82ee72b054a4
  • Loading branch information
redi committed Nov 10, 2017
1 parent 151b9ff commit 9f06171
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 3 deletions.
6 changes: 6 additions & 0 deletions libstdc++-v3/ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
2017-11-10 Jonathan Wakely <jwakely@redhat.com>

PR libstdc++/82917
* include/std/fstream (basic_ifstream::open, basic_ofstream::open)
(basic_fstream::open): Fix missing return.

2017-11-07 Jonathan Wakely <jwakely@redhat.com>

* src/filesystem/ops-common.h (make_file_type) [S_ISSOCK]: Only use
Expand Down
6 changes: 3 additions & 3 deletions libstdc++-v3/include/std/fstream
Original file line number Diff line number Diff line change
Expand Up @@ -663,7 +663,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
template<typename _Path>
auto
open(const _Path& __s, ios_base::openmode __mode = ios_base::in)
-> decltype(_M_filebuf.open(__s, __mode))
-> decltype((void)_M_filebuf.open(__s, __mode))
{ open(__s.c_str(), __mode); }
#endif // C++17
#endif // C++11
Expand Down Expand Up @@ -891,7 +891,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
template<typename _Path>
auto
open(const _Path& __s, ios_base::openmode __mode = ios_base::out)
-> decltype(_M_filebuf.open(__s, __mode))
-> decltype((void)_M_filebuf.open(__s, __mode))
{ open(__s.c_str(), __mode); }
#endif // C++17
#endif // C++11
Expand Down Expand Up @@ -1118,7 +1118,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
auto
open(const _Path& __s,
ios_base::openmode __mode = ios_base::in | ios_base::out)
-> decltype(_M_filebuf.open(__s, __mode))
-> decltype((void)_M_filebuf.open(__s, __mode))
{ open(__s.c_str(), __mode); }
#endif // C++17
#endif // C++11
Expand Down

0 comments on commit 9f06171

Please sign in to comment.