This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [patch] libstdc++/64657 support iterators with overloaded comma operator
- From: François Dumont <frs dot dumont at gmail dot com>
- To: Jonathan Wakely <jwakely at redhat dot com>, libstdc++ at gcc dot gnu dot org, gcc-patches at gcc dot gnu dot org
- Date: Sat, 23 May 2015 13:20:40 +0200
- Subject: Re: [patch] libstdc++/64657 support iterators with overloaded comma operator
- Authentication-results: sourceware.org; auth=none
- References: <20150429152223 dot GL3618 at redhat dot com> <55606253 dot 7030302 at gmail dot com>
On 23/05/2015 13:19, François Dumont wrote:
On 29/04/2015 17:22, Jonathan Wakely wrote:
I think this covers all the places in the library where we do:
++i, ++j
Tested powerpc64le-linux, committed to trunk.
I just committed 2 missing places in debug mode.
2015-05-23 François Dumont fdumont@gcc.gnu.org>
PR libstdc++/64657
* include/debug/functions.h (__check_sorted_aux): Cast expression to
void.
Tested linux x86_64 debug mode in C++11.
François
With the patch.
Index: include/debug/functions.h
===================================================================
--- include/debug/functions.h (revision 223604)
+++ include/debug/functions.h (working copy)
@@ -336,7 +336,7 @@
return true;
_ForwardIterator __next = __first;
- for (++__next; __next != __last; __first = __next, ++__next)
+ for (++__next; __next != __last; __first = __next, (void)++__next)
if (*__next < *__first)
return false;
@@ -362,7 +362,7 @@
return true;
_ForwardIterator __next = __first;
- for (++__next; __next != __last; __first = __next, ++__next)
+ for (++__next; __next != __last; __first = __next, (void)++__next)
if (__pred(*__next, *__first))
return false;