public inbox for libstdc++@gcc.gnu.org
 help / color / mirror / Atom feed
From: Jonathan Wakely <jwakely@redhat.com>
To: Patrick Palka <ppalka@redhat.com>
Cc: gcc-patches@gcc.gnu.org, libstdc++@gcc.gnu.org
Subject: Re: [PATCH] libstdc++: Add a test that takes the split_view of a non-forward range
Date: Wed, 11 Mar 2020 15:57:24 +0000	[thread overview]
Message-ID: <20200311155724.GZ9441@redhat.com> (raw)
In-Reply-To: <20200311154654.837650-1-ppalka@redhat.com>

On 11/03/20 11:46 -0400, Patrick Palka wrote:
>This adds a tests that verifies taking the split_view of a non-forward range
>works correctly.  Doing so revealed a typo in one of _OuterIter's constructors.

Oops!

>It also revealed that the default constructor of
>__gnu_test::test_range::iterator misbehaves, because by delegating to
>Iter<T>(nullptr, nullptr) we perform a null-pointer deref at runtime in
>input_iterator_wrapper's constructor due to the ITERATOR_VERIFY check therein.

Oops for me this time.

>Instead of delegating to this constructor it seems we can just inherit the
>protected default constructor, which does not contain this ITERATOR_VERIFY
>check.

Yep, that makes much more sense.

OK for master, thanks.



      reply	other threads:[~2020-03-11 15:57 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-03-11 15:46 Patrick Palka
2020-03-11 15:57 ` Jonathan Wakely [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20200311155724.GZ9441@redhat.com \
    --to=jwakely@redhat.com \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=libstdc++@gcc.gnu.org \
    --cc=ppalka@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).