public inbox for libstdc++-cvs@sourceware.org help / color / mirror / Atom feed
From: Ian Lance Taylor <ian@gcc.gnu.org> To: gcc-cvs@gcc.gnu.org, libstdc++-cvs@gcc.gnu.org Subject: [gcc/devel/gccgo] libstdc++: Fix warnings with -Wsystem-headers Date: Sun, 12 Jul 2020 20:01:04 +0000 (GMT) [thread overview] Message-ID: <20200712200104.E79B53851C11@sourceware.org> (raw) https://gcc.gnu.org/g:25920dd18ad12ea501309b1487366e22f35db631 commit 25920dd18ad12ea501309b1487366e22f35db631 Author: Jonathan Wakely <jwakely@redhat.com> Date: Wed Jun 24 12:34:17 2020 +0100 libstdc++: Fix warnings with -Wsystem-headers libstdc++-v3/ChangeLog: * include/bits/stl_algobase.h (__find_if): Add FALLTHRU markers. * include/std/charconv (__detail::__to_chars): Avoid -Wsign-compare warning. Diff: --- libstdc++-v3/include/bits/stl_algobase.h | 3 +++ libstdc++-v3/include/std/charconv | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/libstdc++-v3/include/bits/stl_algobase.h b/libstdc++-v3/include/bits/stl_algobase.h index 4fc8850d707..ff5b4505a08 100644 --- a/libstdc++-v3/include/bits/stl_algobase.h +++ b/libstdc++-v3/include/bits/stl_algobase.h @@ -2092,14 +2092,17 @@ _GLIBCXX_END_NAMESPACE_ALGO if (__pred(__first)) return __first; ++__first; + // FALLTHRU case 2: if (__pred(__first)) return __first; ++__first; + // FALLTHRU case 1: if (__pred(__first)) return __first; ++__first; + // FALLTHRU case 0: default: return __last; diff --git a/libstdc++-v3/include/std/charconv b/libstdc++-v3/include/std/charconv index 77a72d40dd0..8fbf64058ee 100644 --- a/libstdc++-v3/include/std/charconv +++ b/libstdc++-v3/include/std/charconv @@ -142,7 +142,7 @@ namespace __detail 'u', 'v', 'w', 'x', 'y', 'z' }; - while (__val >= __base) + while (__val >= (unsigned)__base) { auto const __quo = __val / __base; auto const __rem = __val % __base;
reply other threads:[~2020-07-12 20:01 UTC|newest] Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=20200712200104.E79B53851C11@sourceware.org \ --to=ian@gcc.gnu.org \ --cc=gcc-cvs@gcc.gnu.org \ --cc=libstdc++-cvs@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: linkBe 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).