Message ID | ZD+iyFBUsQQOaSxT@tucnak |
---|---|
State | New |
Headers |
Return-Path: <gcc-patches-bounces+patchwork=sourceware.org@gcc.gnu.org> X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 4CB373858422 for <patchwork@sourceware.org>; Wed, 19 Apr 2023 08:14:41 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 4CB373858422 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1681892081; bh=5rd6mdUTruOvIKURI6dfs3yUcMhwNNXiSyEBBfuLOvI=; 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=qcJNCFOuZ9Wfz6KduOb/p0BdtxMft4AVVbnkqH/mJpfdjJ1QhE6NSdG9WeDIEu5wX 4j6a2GqdkyFfrLYInn/YUk1/9mZIphK2GSap3R6Okl97VRWIpC+OgvsEi1vQ4LDxfj qKmg/9Kv8A9a79c9UFbVMiZrPo8k7LD6QqFztnaI= 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 416DF3858D1E for <gcc-patches@gcc.gnu.org>; Wed, 19 Apr 2023 08:14:11 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 416DF3858D1E 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-622-XzcFzOSbPZ-bVS4CgTe29g-1; Wed, 19 Apr 2023 04:14:09 -0400 X-MC-Unique: XzcFzOSbPZ-bVS4CgTe29g-1 Received: from smtp.corp.redhat.com (int-mx09.intmail.prod.int.rdu2.redhat.com [10.11.54.9]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 6629738123B0; Wed, 19 Apr 2023 08:14:09 +0000 (UTC) Received: from tucnak.zalov.cz (unknown [10.39.194.25]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 2BE46492B04; Wed, 19 Apr 2023 08:14:09 +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 33J8E18D2351118 (version=TLSv1.3 cipher=TLS_AES_256_GCM_SHA384 bits=256 verify=NOT); Wed, 19 Apr 2023 10:14:01 +0200 Received: (from jakub@localhost) by tucnak.zalov.cz (8.17.1/8.17.1/Submit) id 33J8E0e62351117; Wed, 19 Apr 2023 10:14:00 +0200 Date: Wed, 19 Apr 2023 10:14:00 +0200 To: Richard Biener <rguenther@suse.de> Cc: gcc-patches@gcc.gnu.org Subject: [committed] testsuite: Fix up pr109524.C for -std=c++23 [PR109524] Message-ID: <ZD+iyFBUsQQOaSxT@tucnak> References: <20230417084143.A57C2385783F@sourceware.org> MIME-Version: 1.0 In-Reply-To: <20230417084143.A57C2385783F@sourceware.org> X-Scanned-By: MIMEDefang 3.1 on 10.11.54.9 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.7 required=5.0 tests=BAYES_00, DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, 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: Jakub Jelinek via Gcc-patches <gcc-patches@gcc.gnu.org> Reply-To: Jakub Jelinek <jakub@redhat.com> Errors-To: gcc-patches-bounces+patchwork=sourceware.org@gcc.gnu.org Sender: "Gcc-patches" <gcc-patches-bounces+patchwork=sourceware.org@gcc.gnu.org> |
Series |
[committed] testsuite: Fix up pr109524.C for -std=c++23 [PR109524]
|
|
Commit Message
Jakub Jelinek
April 19, 2023, 8:14 a.m. UTC
On Mon, Apr 17, 2023 at 08:41:38AM +0000, Richard Biener via Gcc-patches wrote:
> * g++.dg/pr109524.C: New testcase.
This testcase was reduced such that it isn't valid C++23, so with my
usual testing with GXX_TESTSUITE_STDS=98,11,14,17,20,2b it fails:
FAIL: g++.dg/pr109524.C -std=gnu++2b (test for excess errors)
.../gcc/testsuite/g++.dg/pr109524.C: In function 'nn hh(nn)':
.../gcc/testsuite/g++.dg/pr109524.C:35:12: error: cannot bind non-const lvalue reference of type 'nn&' to an rvalue of type 'nn'
.../gcc/testsuite/g++.dg/pr109524.C:17:6: note: initializing argument 1 of 'nn::nn(nn&)'
The following patch fixes that and I've verified it doesn't change
anything on what the test was testing, it still ICEs in r13-7198 and
passes in r13-7203, now in all language modes (except for 98 where
it is intentionally UNSUPPORTED).
Tested on x86_64-linux -m32/-m64, committed to trunk and 13 branch
as obvious.
2023-04-19 Jakub Jelinek <jakub@redhat.com>
PR tree-optimization/109524
* g++.dg/pr109524.C (nn::nn): Change argument type from nn & to
const nn &.
Jakub
--- gcc/testsuite/g++.dg/pr109524.C.jj 2023-04-17 11:44:12.405551621 +0200 +++ gcc/testsuite/g++.dg/pr109524.C 2023-04-19 09:54:45.211210827 +0200 @@ -14,7 +14,7 @@ struct _Guard { }; struct nn { int * _M_dataplus; - nn(nn &) + nn(const nn &) { f(); _Guard __guard;