From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 1005) id B83293858D34; Fri, 26 Jun 2020 18:02:56 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org B83293858D34 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1593194576; bh=t8dC6Vue58CbkJNe1TTUrbGfYpk2t2WqGdSvBAvN1GA=; h=From:To:Subject:Date:From; b=pE7nSmYw4i1WF/7p8eFSSZrBZE+72BnexPB8C62LWG41Pi0XfgmBDIMDHVzKuQ8F9 9TbXRaMdEz4amI5XtStQrRRkniEta8/fpK41mOh2juyd0ElbtuSmKYNvx2kW8MSieW 8RzlX+K7j8ub3G0HvvPTXAcq+KV5jxe3kUMIWBeo= Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: Michael Meissner To: gcc-cvs@gcc.gnu.org, libstdc++-cvs@gcc.gnu.org Subject: [gcc(refs/users/meissner/heads/work005-orig)] libstdc++: Fix warnings with -Wsystem-headers X-Act-Checkin: gcc X-Git-Author: Jonathan Wakely X-Git-Refname: refs/users/meissner/heads/work005-orig X-Git-Oldrev: be50843754b4c4d47f0d628a84b3dbf2a4145a43 X-Git-Newrev: 25920dd18ad12ea501309b1487366e22f35db631 Message-Id: <20200626180256.B83293858D34@sourceware.org> Date: Fri, 26 Jun 2020 18:02:56 +0000 (GMT) X-BeenThere: libstdc++-cvs@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Libstdc++-cvs mailing list List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 26 Jun 2020 18:02:56 -0000 https://gcc.gnu.org/g:25920dd18ad12ea501309b1487366e22f35db631 commit 25920dd18ad12ea501309b1487366e22f35db631 Author: Jonathan Wakely 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;