From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: 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 19D403858D1E for ; Tue, 2 May 2023 12:50:10 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 19D403858D1E Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=redhat.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=redhat.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1683031809; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=bvJ6uPYsMTyVhyPPUVeqqVHcJy0Fz2rofpLpHLNdLI8=; b=Nv4resuf2vv24nbF34pP3VeJh9jZw+8uIDPL0aQZWYy3joFaE4hUStQjspqtCWNxJLMPJn UTH4scP8rYhliMVrFD7MxP2E7SPYLXECsEmoohIC4hEBGw8/kYdFBdKm5L1hBPtvEoZ+6x SVdaWhinsQ2K3W2H1ttSMKIJKAOmWCY= Received: from mail-qv1-f72.google.com (mail-qv1-f72.google.com [209.85.219.72]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-595-uX6wTpnqPIicFv3OjaiqTQ-1; Tue, 02 May 2023 08:50:08 -0400 X-MC-Unique: uX6wTpnqPIicFv3OjaiqTQ-1 Received: by mail-qv1-f72.google.com with SMTP id 6a1803df08f44-5e7223aab07so21672436d6.0 for ; Tue, 02 May 2023 05:50:08 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1683031808; x=1685623808; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=bvJ6uPYsMTyVhyPPUVeqqVHcJy0Fz2rofpLpHLNdLI8=; b=jPeW9RuUiTusS5k8RH+AvJrobCOFyB20KyMfzF3gY28Yu1sKakguJr2s5FmSw+6odG KfuSMOvJ770Mz8b0Co9S9Ioe3yN96qnK7K1nIL2sX9tghzadqSyQH9x4MtWS1N+JRCX5 hzXgiE+Jna8xToKE3xZPdVZfjo1CNU98pgBVVOeQs1UcNHyyJYaaeH6lOlYQm4xRMuGw dGNqr4gjtG2hhRs+MBz4jRwxw2hdklnt/njiMMNkVtgPXQ7NOk5K/3glSfajE0m0izvr yA8IB4n4HBgnXC9oD0VBNmlWORDAjjtUYXsca8v8A8qFj5VtfgItwIloloBsd2YM9NbN S7/Q== X-Gm-Message-State: AC+VfDz8hcC1tqp08oZoJ/pFnnJ1z+rJQV/12yhQ9TB6sXOp31iN0xE9 QQ+rcRbZnjHwoGCvvpt5T+fj4URpB6Rcjsa/bbsGx1dOLetvJKHGNjF1heM42FlcJLXdVFItEil nX7NaFWZPulHDGufOzHpwPHA4A6fuh1mX8+02MiCuK0uci7s7t1RRQiM5r+pTD1AFXnWj2DMsGS A= X-Received: by 2002:a05:6214:260f:b0:61b:58be:70cd with SMTP id gu15-20020a056214260f00b0061b58be70cdmr5077501qvb.17.1683031807947; Tue, 02 May 2023 05:50:07 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ4Ct9aOYYMA4EDmUDvx5l4brLz9zvdJz+ZjvMwujY70vdbHlZQbbIih9NgqdY7DF3O7PEgJMw== X-Received: by 2002:a05:6214:260f:b0:61b:58be:70cd with SMTP id gu15-20020a056214260f00b0061b58be70cdmr5077467qvb.17.1683031807548; Tue, 02 May 2023 05:50:07 -0700 (PDT) Received: from localhost.localdomain (ool-457670bb.dyn.optonline.net. [69.118.112.187]) by smtp.gmail.com with ESMTPSA id l17-20020a0ce511000000b005dd8b9345dbsm2057116qvm.115.2023.05.02.05.50.06 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 02 May 2023 05:50:07 -0700 (PDT) From: Patrick Palka To: gcc-patches@gcc.gnu.org Cc: jason@redhat.com, Patrick Palka Subject: [pushed] c++: Add testcase for already fixed PR [PR109506] Date: Tue, 2 May 2023 08:50:03 -0400 Message-ID: <20230502125003.1967323-1-ppalka@redhat.com> X-Mailer: git-send-email 2.40.1.459.g48d89b51b3 MIME-Version: 1.0 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset="US-ASCII"; x-default=true X-Spam-Status: No, score=-13.8 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 List-Id: The PR109666 fix r14-386-g07c52d1eec967 incidentally also fixes this PR. PR c++/109506 gcc/testsuite/ChangeLog: * g++.dg/cpp0x/nsdmi-template26.C: New test. --- gcc/testsuite/g++.dg/cpp0x/nsdmi-template26.C | 22 +++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 gcc/testsuite/g++.dg/cpp0x/nsdmi-template26.C diff --git a/gcc/testsuite/g++.dg/cpp0x/nsdmi-template26.C b/gcc/testsuite/g++.dg/cpp0x/nsdmi-template26.C new file mode 100644 index 00000000000..032b7b61619 --- /dev/null +++ b/gcc/testsuite/g++.dg/cpp0x/nsdmi-template26.C @@ -0,0 +1,22 @@ +// PR c++/109506 +// { dg-do link { target c++11 } } +// { dg-additional-options "-fchecking=2" } + +template +struct foo { + foo() { }; +}; + +template +class bar { + foo alloc_{}; +}; + +template +bar func1() { + return bar{}; +} + +int main() { + func1(); +} -- 2.40.1.459.g48d89b51b3