From patchwork Tue Sep 22 20:30:07 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Patrick Palka X-Patchwork-Id: 1369252 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=gcc.gnu.org (client-ip=8.43.85.97; helo=sourceware.org; envelope-from=gcc-patches-bounces@gcc.gnu.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=gcc.gnu.org Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=gcc.gnu.org header.i=@gcc.gnu.org header.a=rsa-sha256 header.s=default header.b=lz58y4NR; dkim-atps=neutral Received: from sourceware.org (server2.sourceware.org [8.43.85.97]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 4BwtGg4GkCz9sS8 for ; Wed, 23 Sep 2020 06:30:18 +1000 (AEST) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 49C45398B8AE; Tue, 22 Sep 2020 20:30:15 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 49C45398B8AE DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1600806615; bh=eLqQ9+aLKzxEhH5NTYWEaTznlPYWY6voSqTiSx+9q7s=; h=To:Subject:Date:List-Id:List-Unsubscribe:List-Archive:List-Post: List-Help:List-Subscribe:From:Reply-To:From; b=lz58y4NR/pVvDZZKgTF4RknLFWS6gmNOvfvD8BBpGXtvaccYkT9SdVdSapLWsGFH4 tu3jS5HVsP7T4HNi1E9KP+j+BikhyZwAjV3cfXN58a/zqZJz59oHNueZ2qpffmAYAt b9l69r5cEaiH4duUNHSTIB9l7YpIjoc7fsjjJ9WQ= 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 [216.205.24.124]) by sourceware.org (Postfix) with ESMTP id 5A172385780B for ; Tue, 22 Sep 2020 20:30:13 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org 5A172385780B Received: from mail-qk1-f200.google.com (mail-qk1-f200.google.com [209.85.222.200]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-183-1ddvKo3mPgqVngPSTZZ--A-1; Tue, 22 Sep 2020 16:30:11 -0400 X-MC-Unique: 1ddvKo3mPgqVngPSTZZ--A-1 Received: by mail-qk1-f200.google.com with SMTP id m23so14728842qkh.10 for ; Tue, 22 Sep 2020 13:30:10 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=eLqQ9+aLKzxEhH5NTYWEaTznlPYWY6voSqTiSx+9q7s=; b=bK502AJJZrlq+mQwUbqvxpq7ouc8xADINjx5lW4Sadv0dVhwzQL5dmuy4C/oC1Xqx9 SaoDQ0c8hr+7UtuDkqoPywsPuWXj05n1ccOtaf183InhymmC+EjYEVY7gi7jiyxNCOxS Sg8fhczSLWWO+Qkcecfb0k8LVdFLAJv/XZLG+jqS4ZTLXRx8nbXpK2jBrbEj/4TN8cYE gk9eVDPZZKvXxL33hPsHPM9WvOMQaRa8gJrw7OZ3B9+rM28GIckCL+CsnVrGgAjyDZuL ESpGfWg3UUCnlrcOk4mAAzD7VmZdutYtsneLK9CmC8san3Dj9pt93aKRPwp//tFzoLs6 JV4A== X-Gm-Message-State: AOAM533TcYrKo5cEAXpJr0RSn7T6pgEcmM84d/Wv6tN9+rXNRSzJ2Aet d/jBIcL0Gfn9XhrLI0SCJ9khSGzuZaHj+SUy5Frwj9VR6qryO90npUZxjpIuo5vajNuyNbuaXlr ogy66FVG93nLGW19xbQ== X-Received: by 2002:ac8:b8b:: with SMTP id h11mr6386377qti.28.1600806610147; Tue, 22 Sep 2020 13:30:10 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwmRpKGB6Z0y8yoXqDuVNwWG4cILznlKgJH+clXyxZL5Kagi4WyMDSXWtKqW25tIOgNAsMk7w== X-Received: by 2002:ac8:b8b:: with SMTP id h11mr6386361qti.28.1600806609873; Tue, 22 Sep 2020 13:30:09 -0700 (PDT) Received: from localhost.localdomain (ool-457d493a.dyn.optonline.net. [69.125.73.58]) by smtp.gmail.com with ESMTPSA id m18sm13095226qkg.77.2020.09.22.13.30.08 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 22 Sep 2020 13:30:09 -0700 (PDT) To: gcc-patches@gcc.gnu.org Subject: [COMMITTED] c++: Add test for PR96652 Date: Tue, 22 Sep 2020 16:30:07 -0400 Message-Id: <20200922203007.435001-1-ppalka@redhat.com> X-Mailer: git-send-email 2.28.0.497.g54e85e7af1 MIME-Version: 1.0 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com X-Spam-Status: No, score=-16.1 required=5.0 tests=BAYES_00, DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, GIT_PATCH_0, KAM_NUMSUBJECT, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H5, RCVD_IN_MSPIKE_WL, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) 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 List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-Patchwork-Original-From: Patrick Palka via Gcc-patches From: Patrick Palka Reply-To: Patrick Palka Errors-To: gcc-patches-bounces@gcc.gnu.org Sender: "Gcc-patches" Fixed by r11-3361. gcc/testsuite/ChangeLog: PR c++/96652 * g++.dg/cpp0x/decltype-96652.C: New test. --- gcc/testsuite/g++.dg/cpp0x/decltype-96652.C | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 gcc/testsuite/g++.dg/cpp0x/decltype-96652.C diff --git a/gcc/testsuite/g++.dg/cpp0x/decltype-96652.C b/gcc/testsuite/g++.dg/cpp0x/decltype-96652.C new file mode 100644 index 00000000000..249cce2b9e8 --- /dev/null +++ b/gcc/testsuite/g++.dg/cpp0x/decltype-96652.C @@ -0,0 +1,14 @@ +// PR c++/96652 +// { dg-do compile { target c++11 } } + +struct A {}; + +template +struct B +{ + A m; + friend decltype(m); +}; + +A a; +B b;