Message ID | 20230517190607.2023676-1-jwakely@redhat.com |
---|---|
State | Accepted |
Headers |
Return-Path: <gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b0ea:0:b0:3b6:4342:cba0 with SMTP id b10csp1360482vqo; Wed, 17 May 2023 12:08:37 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ4Dv5DOyawxgPoT5f6NuFKR65KW9e2lB1ro0pSnPmCpJJXg5GqnieZqAqcqKa8ShaLJlE1q X-Received: by 2002:a17:907:9304:b0:94a:7716:e649 with SMTP id bu4-20020a170907930400b0094a7716e649mr37354275ejc.13.1684350517510; Wed, 17 May 2023 12:08:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1684350517; cv=none; d=google.com; s=arc-20160816; b=ww4N+MjlUoDRGO+BrHs9T04PnjGk6TWEgAIjwI2CuN/HE06ksBAJdETSvSaEuIucOM HINn+MNXEsYFDORMePRljO6nqJjdAmWywkQIJ4pZA0KB1qJ4B7L39ZQe/z50gYtaf1m9 FJfLmjeDSCbHmk3oRduIOqh8tC4FcPKQxiVVIMVxjR0MfXoPi/agyJgrX5no3SkwHDD+ jH+OrN96LHVLz1LPWvp74drHvwD1drih53uN9944LxcC2SJvFMj7dZwHCJvcozL7eSwx ttpvptWj/z03UNjAqe05TuylVOqqtC1r/QBsgwiKDxeJZPt+zLKTjohUG57MiPIQFv/c fF1A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:reply-to:from:list-subscribe:list-help:list-post :list-archive:list-unsubscribe:list-id:precedence :content-transfer-encoding:mime-version:message-id:date:subject:to :dmarc-filter:delivered-to:dkim-signature:dkim-filter; bh=zjXahUPOFWSiouULnv+pa6UXcREAcmHl7WI8Cp18fuI=; b=ct0kU32PmToVmHQxGrcxZeJHbRFGC65x+zzZY1Nf0edm6JlikoremYgnhgCpjnkScd 7XCetWxyUkEbo+U/51VvG9MErCw/jaBsEi73Y5Jl800CAE2USrHhM5MdBco7/NycbsRi BkMAn/jP7nWT0zP8SBAtXsjOhr66rErvQ+3/0UBRy3MR2DvWlWHm82grn6x/+W1/han9 jBynD/BF9j+PqIrto4pmojoR0JcgroLK60O8Scdg6IWSIBNvcsXgABx3Gkms6xl2ript eA6WUqacMzmnjUIo6MLFC3qVgVdqhekpvXSl49qeDsi43RMULPaLH4XZvdb2wV3oE6GC c4rQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gcc.gnu.org header.s=default header.b=cStIBm+l; spf=pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 8.43.85.97 as permitted sender) smtp.mailfrom="gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=gnu.org Received: from sourceware.org (ip-8-43-85-97.sourceware.org. [8.43.85.97]) by mx.google.com with ESMTPS id d19-20020a1709061f5300b009662c796238si15998130ejk.1010.2023.05.17.12.08.37 for <ouuuleilei@gmail.com> (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 17 May 2023 12:08:37 -0700 (PDT) Received-SPF: pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 8.43.85.97 as permitted sender) client-ip=8.43.85.97; Authentication-Results: mx.google.com; dkim=pass header.i=@gcc.gnu.org header.s=default header.b=cStIBm+l; spf=pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 8.43.85.97 as permitted sender) smtp.mailfrom="gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=gnu.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 8214C3839067 for <ouuuleilei@gmail.com>; Wed, 17 May 2023 19:07:24 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 8214C3839067 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1684350444; bh=zjXahUPOFWSiouULnv+pa6UXcREAcmHl7WI8Cp18fuI=; h=To:Subject:Date:List-Id:List-Unsubscribe:List-Archive:List-Post: List-Help:List-Subscribe:From:Reply-To:From; b=cStIBm+lGK3/X7a5nnxQ+hlDkQbesOFEtLkfFLHswO3Pbc7KuUka6vqFdHrzzpE4V TrDxQG+FHVgU1jyW11iTT3ct5DEzWH02oUwBdi/92AAbDe0LjVbbu1nTr/NQ7CdaZj rgI7yrc1v25DyaGLmx59KQGZt2jgUjLJcGT3kTak= X-Original-To: gcc-patches@gcc.gnu.org Delivered-To: gcc-patches@gcc.gnu.org Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by sourceware.org (Postfix) with ESMTPS id A629A384645F for <gcc-patches@gcc.gnu.org>; Wed, 17 May 2023 19:06:12 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org A629A384645F Received: from mimecast-mx02.redhat.com (mx3-rdu2.redhat.com [66.187.233.73]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-542-Ug7TYCzxPGCMlFPEalOBMA-1; Wed, 17 May 2023 15:06:09 -0400 X-MC-Unique: Ug7TYCzxPGCMlFPEalOBMA-1 Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.rdu2.redhat.com [10.11.54.4]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id C9DCC3C0C880; Wed, 17 May 2023 19:06:08 +0000 (UTC) Received: from localhost (unknown [10.42.28.178]) by smtp.corp.redhat.com (Postfix) with ESMTP id 954442026D16; Wed, 17 May 2023 19:06:08 +0000 (UTC) To: libstdc++@gcc.gnu.org, gcc-patches@gcc.gnu.org Subject: [committed] libstdc++: Add system_header pragma to <bits/c++config.h> Date: Wed, 17 May 2023 20:06:07 +0100 Message-Id: <20230517190607.2023676-1-jwakely@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.1 on 10.11.54.4 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-12.1 required=5.0 tests=BAYES_00, DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2, SPF_HELO_NONE, SPF_NONE, TXREP, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: gcc-patches@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-patches mailing list <gcc-patches.gcc.gnu.org> List-Unsubscribe: <https://gcc.gnu.org/mailman/options/gcc-patches>, <mailto:gcc-patches-request@gcc.gnu.org?subject=unsubscribe> List-Archive: <https://gcc.gnu.org/pipermail/gcc-patches/> List-Post: <mailto:gcc-patches@gcc.gnu.org> List-Help: <mailto:gcc-patches-request@gcc.gnu.org?subject=help> List-Subscribe: <https://gcc.gnu.org/mailman/listinfo/gcc-patches>, <mailto:gcc-patches-request@gcc.gnu.org?subject=subscribe> From: Jonathan Wakely via Gcc-patches <gcc-patches@gcc.gnu.org> Reply-To: Jonathan Wakely <jwakely@redhat.com> Errors-To: gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org Sender: "Gcc-patches" <gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org> X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1766169528019706544?= X-GMAIL-MSGID: =?utf-8?q?1766169528019706544?= |
Series |
[committed] libstdc++: Add system_header pragma to <bits/c++config.h>
|
|
Checks
Context | Check | Description |
---|---|---|
snail/gcc-patch-check | success | Github commit url |
Commit Message
Jonathan Wakely
May 17, 2023, 7:06 p.m. UTC
Tested powerpc64le-linux. Pushed to trunk. -- >8 -- Without this change many tests that depend on an effective-target will fail when compiled with -pedantic -std=c++98. This happens because the preprocessor check done by v3_check_preprocessor_condition uses -Werror and includes <bits/c++config.h> directly (rather than via another header like <string>). If <bits/c++config.h> is not a system header then this pedwarn is not suppressed, and the effective-target check fails: bits/c++config.h:220: error: anonymous variadic macros were introduced in C++11 [-Werror=variadic-macros] cc1plus: all warnings being treated as errors compiler exited with status 1 UNSUPPORTED: 18_support/headers/limits/synopsis.cc We could consider also changing proc v3_check_preprocessor_condition so that it includes a real header, rather than just <bits/c++config.h>, but that's not necessary for now. libstdc++-v3/ChangeLog: * include/bits/c++config: Add system_header pragma. --- libstdc++-v3/include/bits/c++config | 2 ++ 1 file changed, 2 insertions(+)
diff --git a/libstdc++-v3/include/bits/c++config b/libstdc++-v3/include/bits/c++config index 13892787e09..009a017b048 100644 --- a/libstdc++-v3/include/bits/c++config +++ b/libstdc++-v3/include/bits/c++config @@ -30,6 +30,8 @@ #ifndef _GLIBCXX_CXX_CONFIG_H #define _GLIBCXX_CXX_CONFIG_H 1 +#pragma GCC system_header + // The major release number for the GCC release the C++ library belongs to. #define _GLIBCXX_RELEASE