From: Jonathan Wakely <jwakely@redhat.com>
To: "François Dumont" <frs.dumont@gmail.com>
Cc: "libstdc++@gcc.gnu.org" <libstdc++@gcc.gnu.org>,
gcc-patches <gcc-patches@gcc.gnu.org>
Subject: Re: [PATCH][_GLIBCXX_DEBUG] Review null string assertions (was: Add basic_string::starts_with/ends_with checks)
Date: Wed, 31 Aug 2022 10:25:39 +0100 [thread overview]
Message-ID: <CACb0b4=2BzOwqWU2xSkA5dfxjzCTFWpA0MOHQNUNzXEdEorb+A@mail.gmail.com> (raw)
In-Reply-To: <d277c844-d9fe-a679-3d92-59f70f932a76@gmail.com>
On Wed, 31 Aug 2022 at 05:38, François Dumont <frs.dumont@gmail.com> wrote:
>
> If I got your point correctly here is this patch again with just the
> change on '0' becoming 'nullptr' in assertions.
>
> libstdc++: [_GLIBCXX_DEBUG] Review nullptr assertion diagnostics
>
> Review null string checks to show:
> _String != nullptr
>
> rather than:
> _String != 0
>
> libstdc++-v3/ChangeLog:
>
> * include/debug/debug.h: Use nullptr rather than '0' in
> checks in post-C++11.
> * include/debug/string: Likewise.
> *
> testsuite/21_strings/basic_string/operations/ends_with/char.cc: Use
> __gnu_test::string.
> *
> testsuite/21_strings/basic_string/operations/ends_with/nonnull.cc: Likewise.
> *
> testsuite/21_strings/basic_string/operations/ends_with/wchar_t.cc: Likewise.
> *
> testsuite/21_strings/basic_string/operations/starts_with/wchar_t.cc:
> Likewise.
> *
> testsuite/21_strings/basic_string/operations/starts_with/nonnull.cc:
> Likewise.
> *
> testsuite/21_strings/basic_string/operations/starts_with/char.cc: Likewise..
>
> Ok to commit ?
The testsuite changes seem unrelated to the actual code change, so I'd
have done a separate patch. But OK for trunk.
prev parent reply other threads:[~2022-08-31 9:25 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-08-14 15:32 [PATCH][_GLIBCXX_DEBUG] Add basic_string::starts_with/ends_with checks François Dumont
2022-08-15 20:26 ` François Dumont
2022-08-25 16:11 ` François Dumont
2022-08-26 9:33 ` Jonathan Wakely
2022-08-26 9:31 ` Jonathan Wakely
2022-08-31 4:38 ` [PATCH][_GLIBCXX_DEBUG] Review null string assertions (was: Add basic_string::starts_with/ends_with checks) François Dumont
2022-08-31 9:25 ` 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='CACb0b4=2BzOwqWU2xSkA5dfxjzCTFWpA0MOHQNUNzXEdEorb+A@mail.gmail.com' \
--to=jwakely@redhat.com \
--cc=frs.dumont@gmail.com \
--cc=gcc-patches@gcc.gnu.org \
--cc=libstdc++@gcc.gnu.org \
/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).