[committed] testsuite: Expect -Wdeprecated warning in warn/Wstrict-aliasing-bogus-union-2.C for C++23
Message ID | Y+IY7Er3m7bAxKCS@tucnak |
---|---|
State | Unresolved |
Headers |
Return-Path: <gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:eb09:0:0:0:0:0 with SMTP id s9csp2743422wrn; Tue, 7 Feb 2023 01:25:52 -0800 (PST) X-Google-Smtp-Source: AK7set83YKPmaCmYUVzDJOagnD7KgZENTAFOxqnt52EVqWh6mUZiYLGlSv2o+ntn86MUwCW59f7h X-Received: by 2002:a50:a44e:0:b0:4aa:b2d3:eb2f with SMTP id v14-20020a50a44e000000b004aab2d3eb2fmr2711157edb.38.1675761951972; Tue, 07 Feb 2023 01:25:51 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1675761951; cv=none; d=google.com; s=arc-20160816; b=PC8Tq8v0ksaUIDwZGWTurU82M+9v1x1nEGFtDieB1TqsNg+dCLWKpBgSydaC/U4XRT 0fRyXe/ypUh9uqWAWVvHHenKuUU04f+h0FHtFYaWBvcuS8IH7f/98UXPZW7UVRG2a5aa LVokEmzxd0pBexntJuSAVIgpE/mEN/LbOPco6TcHTsUK0buB6EcaOmBrckYMAwQibaII Uz968kZQ2ESeheNAm1N4piksEDPJDh7Dr8hccvGN8e9ijTc4YWc5L1vFQ9DG8oSNQy8m MuPWe8+ZmQUAGNtz771GTVjGJ05Cw6HbfdM94FXY9be7b57VQ0xnYjNxyZ8Glf5pPJkz SuNA== 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-disposition:in-reply-to:mime-version:references:message-id :subject:cc:to:date:dmarc-filter:delivered-to:dkim-signature :dkim-filter; bh=mZxyXWWvOKUCYXx+eULt1uS3fBM1dze/T1JyF4VhaRk=; b=OcYCQJHg2Zd3wugyitNjvBs4BTnJ2qNYD5tMycLCJLUNnU6VwdsyYfsA2ImzWdnXYg HkMPiTxU8in3kR/HURrOPr5I4BwMYMOxJaJJlezp3Z/shi9Sn0/1Qd+MewKISwoBserr n5+Jox/1OUdAwbeIdUxJakGrD4I8anyDsD+E0qmpHSI95cxyBj7BJUpMXq5Lcv+53Az3 Wd1RVUmv73seCCkwozHS2uF/+YW0njvV0vI2R0MqP/ZYKEpq2IaWJPYjtiVBVI0ELDjs oMatq3LtVXckTo+BhXfECfSYe8pOnhxwXHrH+L8Y3n6Jbx8WTZ6xB3yz1m5D41xFt/Fd wrEg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gcc.gnu.org header.s=default header.b=FTMXVbY5; spf=pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 2620:52:3:1:0:246e:9693:128c 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 (server2.sourceware.org. [2620:52:3:1:0:246e:9693:128c]) by mx.google.com with ESMTPS id fd25-20020a056402389900b004a2662c3f8asi15490364edb.98.2023.02.07.01.25.51 for <ouuuleilei@gmail.com> (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 07 Feb 2023 01:25:51 -0800 (PST) Received-SPF: pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 2620:52:3:1:0:246e:9693:128c as permitted sender) client-ip=2620:52:3:1:0:246e:9693:128c; Authentication-Results: mx.google.com; dkim=pass header.i=@gcc.gnu.org header.s=default header.b=FTMXVbY5; spf=pass (google.com: domain of gcc-patches-bounces+ouuuleilei=gmail.com@gcc.gnu.org designates 2620:52:3:1:0:246e:9693:128c 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 BD0F43858C36 for <ouuuleilei@gmail.com>; Tue, 7 Feb 2023 09:25:50 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org BD0F43858C36 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1675761950; bh=mZxyXWWvOKUCYXx+eULt1uS3fBM1dze/T1JyF4VhaRk=; h=Date:To:Cc:Subject:References:In-Reply-To:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From:Reply-To:From; b=FTMXVbY5gGqHRi/dZuFrqwUYkv5tEZB2BjSeN6zzbuHdZNt981MVFIRQ7wCPvW6x+ M7J9ADiplUnWjZ4nwoyTR41la71MPl+2zuzdYs+tGasDThFmj+riTi2a4ou1AHM8BS FWbfq5QEPzr6tdF3jUW6qi7nhfzr17fXq/lUxqbY= 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.129.124]) by sourceware.org (Postfix) with ESMTPS id 3D3D83858D33 for <gcc-patches@gcc.gnu.org>; Tue, 7 Feb 2023 09:25:06 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 3D3D83858D33 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-241-AQvBJJL-MuqyhHfcsLdNow-1; Tue, 07 Feb 2023 04:25:04 -0500 X-MC-Unique: AQvBJJL-MuqyhHfcsLdNow-1 Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.rdu2.redhat.com [10.11.54.5]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 3F2932800484 for <gcc-patches@gcc.gnu.org>; Tue, 7 Feb 2023 09:25:04 +0000 (UTC) Received: from tucnak.zalov.cz (unknown [10.39.192.223]) by smtp.corp.redhat.com (Postfix) with ESMTPS id F059E440DE; Tue, 7 Feb 2023 09:25:03 +0000 (UTC) Received: from tucnak.zalov.cz (localhost [127.0.0.1]) by tucnak.zalov.cz (8.17.1/8.17.1) with ESMTPS id 3179P1x3979388 (version=TLSv1.3 cipher=TLS_AES_256_GCM_SHA384 bits=256 verify=NOT); Tue, 7 Feb 2023 10:25:02 +0100 Received: (from jakub@localhost) by tucnak.zalov.cz (8.17.1/8.17.1/Submit) id 3179P18M979387; Tue, 7 Feb 2023 10:25:01 +0100 Date: Tue, 7 Feb 2023 10:25:00 +0100 To: Jonathan Wakely <jwakely@redhat.com>, Jason Merrill <jason@redhat.com> Cc: gcc-patches@gcc.gnu.org Subject: [committed] testsuite: Expect -Wdeprecated warning in warn/Wstrict-aliasing-bogus-union-2.C for C++23 Message-ID: <Y+IY7Er3m7bAxKCS@tucnak> References: <20230206142601.2970070-1-jwakely@redhat.com> MIME-Version: 1.0 In-Reply-To: <20230206142601.2970070-1-jwakely@redhat.com> X-Scanned-By: MIMEDefang 3.1 on 10.11.54.5 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset=us-ascii Content-Disposition: inline X-Spam-Status: No, score=-3.6 required=5.0 tests=BAYES_00, DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, KAM_NUMSUBJECT, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2, SPF_HELO_NONE, SPF_NONE, TXREP autolearn=no 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: Jakub Jelinek via Gcc-patches <gcc-patches@gcc.gnu.org> Reply-To: Jakub Jelinek <jakub@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?1757163764481729949?= X-GMAIL-MSGID: =?utf-8?q?1757163764481729949?= |
Series |
[committed] testsuite: Expect -Wdeprecated warning in warn/Wstrict-aliasing-bogus-union-2.C for C++23
|
|
Checks
Context | Check | Description |
---|---|---|
snail/gcc-patch-check | warning | Git am fail log |
Commit Message
Jakub Jelinek
Feb. 7, 2023, 9:25 a.m. UTC
Hi! On Mon, Feb 06, 2023 at 02:26:01PM +0000, Jonathan Wakely via Gcc-patches wrote: > With the recent change to deprecate std::aligned_storage and > std::aligned_union we need to adjust some tests that now fail with > -std=c++23. The g++.dg/warn/Wstrict-aliasing-bogus-union-2.C test is also affected: PASS: g++.dg/warn/Wstrict-aliasing-bogus-union-2.C -std=gnu++2b (test for bogus messages, line 12) FAIL: g++.dg/warn/Wstrict-aliasing-bogus-union-2.C -std=gnu++2b (test for excess errors) Excess errors: .../gcc/testsuite/g++.dg/warn/Wstrict-aliasing-bogus-union-2.C:8:8: warning: 'template<long unsigned int _Len, long unsigned int _Align> struct std::aligned_storage' is deprecated [-Wdeprecated-declarations] The following patch adds dg-warning for it. Tested on x86_64-linux -m32/-m64 with GXX_TESTSUITE_STDS=98,11,14,17,20,2b , committed to trunk as obvious. 2023-02-07 Jakub Jelinek <jakub@redhat.com> * g++.dg/warn/Wstrict-aliasing-bogus-union-2.C: Expect -Wdeprecated warning for C++23. Jakub
Comments
On Tue, 7 Feb 2023 at 09:25, Jakub Jelinek <jakub@redhat.com> wrote: > > Hi! > > On Mon, Feb 06, 2023 at 02:26:01PM +0000, Jonathan Wakely via Gcc-patches wrote: > > With the recent change to deprecate std::aligned_storage and > > std::aligned_union we need to adjust some tests that now fail with > > -std=c++23. > > The g++.dg/warn/Wstrict-aliasing-bogus-union-2.C test is also affected: > PASS: g++.dg/warn/Wstrict-aliasing-bogus-union-2.C -std=gnu++2b (test for bogus messages, line 12) > FAIL: g++.dg/warn/Wstrict-aliasing-bogus-union-2.C -std=gnu++2b (test for excess errors) > Excess errors: > .../gcc/testsuite/g++.dg/warn/Wstrict-aliasing-bogus-union-2.C:8:8: warning: 'template<long unsigned int _Len, long unsigned int _Align> struct std::aligned_storage' is deprecated [-Wdeprecated-declarations] > > The following patch adds dg-warning for it. > > Tested on x86_64-linux -m32/-m64 with GXX_TESTSUITE_STDS=98,11,14,17,20,2b , > committed to trunk as obvious. Oops, sorry about that - I must remember to check the g++ tests for any header and deprecation changes.
--- gcc/testsuite/g++.dg/warn/Wstrict-aliasing-bogus-union-2.C.jj 2020-01-12 11:54:37.286400238 +0100 +++ gcc/testsuite/g++.dg/warn/Wstrict-aliasing-bogus-union-2.C 2023-02-07 10:21:47.616642483 +0100 @@ -5,7 +5,7 @@ struct foo { - std::aligned_storage<sizeof(long), alignof(long)>::type raw; + std::aligned_storage<sizeof(long), alignof(long)>::type raw; /* { dg-warning "deprecated" "" { target c++23 } } */ long& cooked() {