This is the mail archive of the
libstdc++@gcc.gnu.org
mailing list for the libstdc++ project.
Re: [PATCH] streambuf_iterator: avoid debug-dependent behaviour
- From: Jonathan Wakely <jwakely at redhat dot com>
- To: Petr Ovtchenkov <ptr at void-ptr dot info>
- Cc: libstdc++ at gcc dot gnu dot org, gcc-patches at gcc dot gnu dot org
- Date: Fri, 1 Sep 2017 10:10:37 +0100
- Subject: Re: [PATCH] streambuf_iterator: avoid debug-dependent behaviour
- Authentication-results: sourceware.org; auth=none
- Authentication-results: ext-mx06.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=redhat.com
- Authentication-results: ext-mx06.extmail.prod.ext.phx2.redhat.com; spf=fail smtp.mailfrom=jwakely at redhat dot com
- Dmarc-filter: OpenDMARC Filter v1.3.2 mx1.redhat.com 205DE3B724
- References: <E1dkqHr-0008T4-Qa@void-ptr.info>
On 24/08/17 12:57 +0300, Petr Ovtchenkov wrote:
Explicit do sgetc from associated streambuf. Avoid debug-dependent
sgetc (within _M_at_eof()):
__glibcxx_requires_cond(!_M_at_eof(),
_M_message(__gnu_debug::__msg_inc_istreambuf)
._M_iterator(*this));
Increment operators not require not-eof precoditions.
Don't unlink associated streambuf if eof detected (in _M_get).
Clean logic in postfix increment operator.
I find it very hard to understand the reasons for this patch. What
you've written above is too terse for me.
Are you fixing a bug? If so, do you have a testcase that demonstrates
the problem, and is fixed by these changes?
Is this just refactoring, without changing behaviour?
Finally, and very importantly, do you have a copyright assignment for
changes to GCC? See https://gcc.gnu.org/contribute.html#legal