This is the mail archive of the
libstdc++@gcc.gnu.org
mailing list for the libstdc++ project.
[PATCH] missing return in debug/vector _Safe_vector::operator=
- From: Stephan Bergmann <sbergman at redhat dot com>
- To: libstdc++ at gcc dot gnu dot org
- Date: Tue, 28 Apr 2015 14:32:22 +0200
- Subject: [PATCH] missing return in debug/vector _Safe_vector::operator=
- Authentication-results: sourceware.org; auth=none
broken on GCC 5 and trunk
Index: libstdc++-v3/ChangeLog
===================================================================
--- libstdc++-v3/ChangeLog (revision 222523)
+++ libstdc++-v3/ChangeLog (working copy)
@@ -1,3 +1,8 @@
+2015-04-28 Stephan Bergmann <sbergman@redhat.com>
+
+ * include/debug/vector (__gnu_debug):
+ Add missing return in _Safe_vector::operator=
+
2015-04-28 Jonathan Wakely <jwakely@redhat.com>
* libsupc++/exception (uncaught_exceptions): Add comment. Reorder #if.
Index: libstdc++-v3/include/debug/vector
===================================================================
--- libstdc++-v3/include/debug/vector (revision 222523)
+++ libstdc++-v3/include/debug/vector (working copy)
@@ -69,7 +69,10 @@
_Safe_vector&
operator=(const _Safe_vector&) noexcept
- { _M_update_guaranteed_capacity(); }
+ {
+ _M_update_guaranteed_capacity();
+ return *this;
+ }
_Safe_vector&
operator=(_Safe_vector&& __x) noexcept
@@ -76,6 +79,7 @@
{
_M_update_guaranteed_capacity();
__x._M_guaranteed_capacity = 0;
+ return *this;
}
#endif