{"id":2225238,"url":"http://patchwork.ozlabs.org/api/1.1/patches/2225238/?format=json","web_url":"http://patchwork.ozlabs.org/project/gcc/patch/20260420170859.370095-1-polacek@redhat.com/","project":{"id":17,"url":"http://patchwork.ozlabs.org/api/1.1/projects/17/?format=json","name":"GNU Compiler Collection","link_name":"gcc","list_id":"gcc-patches.gcc.gnu.org","list_email":"gcc-patches@gcc.gnu.org","web_url":null,"scm_url":null,"webscm_url":null},"msgid":"<20260420170859.370095-1-polacek@redhat.com>","date":"2026-04-20T17:08:59","name":"c++/reflection: improve diagnostic for dependent splices","commit_ref":null,"pull_url":null,"state":"new","archived":false,"hash":"cd6b166f620fbdb632ccc0a1820c5a94d2ca3920","submitter":{"id":14370,"url":"http://patchwork.ozlabs.org/api/1.1/people/14370/?format=json","name":"Marek Polacek","email":"polacek@redhat.com"},"delegate":null,"mbox":"http://patchwork.ozlabs.org/project/gcc/patch/20260420170859.370095-1-polacek@redhat.com/mbox/","series":[{"id":500645,"url":"http://patchwork.ozlabs.org/api/1.1/series/500645/?format=json","web_url":"http://patchwork.ozlabs.org/project/gcc/list/?series=500645","date":"2026-04-20T17:08:59","name":"c++/reflection: improve diagnostic for dependent splices","version":1,"mbox":"http://patchwork.ozlabs.org/series/500645/mbox/"}],"comments":"http://patchwork.ozlabs.org/api/patches/2225238/comments/","check":"pending","checks":"http://patchwork.ozlabs.org/api/patches/2225238/checks/","tags":{},"headers":{"Return-Path":"<gcc-patches-bounces~incoming=patchwork.ozlabs.org@gcc.gnu.org>","X-Original-To":["incoming@patchwork.ozlabs.org","gcc-patches@gcc.gnu.org"],"Delivered-To":["patchwork-incoming@legolas.ozlabs.org","gcc-patches@gcc.gnu.org"],"Authentication-Results":["legolas.ozlabs.org;\n\tdkim=pass (1024-bit key;\n unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256\n header.s=mimecast20190719 header.b=F+PlyM51;\n\tdkim-atps=neutral","legolas.ozlabs.org;\n spf=pass (sender SPF authorized) smtp.mailfrom=gcc.gnu.org\n (client-ip=2620:52:6:3111::32; helo=vm01.sourceware.org;\n envelope-from=gcc-patches-bounces~incoming=patchwork.ozlabs.org@gcc.gnu.org;\n receiver=patchwork.ozlabs.org)","sourceware.org;\n\tdkim=pass (1024-bit key,\n unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256\n header.s=mimecast20190719 header.b=F+PlyM51","sourceware.org; dmarc=pass (p=quarantine dis=none)\n header.from=redhat.com","sourceware.org; spf=pass smtp.mailfrom=redhat.com","server2.sourceware.org;\n arc=none smtp.remote-ip=170.10.133.124"],"Received":["from vm01.sourceware.org (vm01.sourceware.org\n [IPv6:2620:52:6:3111::32])\n\t(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)\n\t key-exchange x25519 server-signature ECDSA (secp384r1) server-digest SHA384)\n\t(No client certificate requested)\n\tby legolas.ozlabs.org (Postfix) with ESMTPS id 4fzsRc3WLYz1yGs\n\tfor <incoming@patchwork.ozlabs.org>; Tue, 21 Apr 2026 03:09:47 +1000 (AEST)","from vm01.sourceware.org (localhost [127.0.0.1])\n\tby sourceware.org (Postfix) with ESMTP id 0B7A24AA54C6\n\tfor <incoming@patchwork.ozlabs.org>; Mon, 20 Apr 2026 17:09:45 +0000 (GMT)","from us-smtp-delivery-124.mimecast.com\n (us-smtp-delivery-124.mimecast.com [170.10.133.124])\n by sourceware.org (Postfix) with ESMTP id 555B34BC0577\n for <gcc-patches@gcc.gnu.org>; Mon, 20 Apr 2026 17:09:16 +0000 (GMT)","from mx-prod-mc-08.mail-002.prod.us-west-2.aws.redhat.com\n (ec2-35-165-154-97.us-west-2.compute.amazonaws.com [35.165.154.97]) by\n relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3,\n cipher=TLS_AES_256_GCM_SHA384) id us-mta-450-i8xThJWVPjyms38tR_OU0g-1; Mon,\n 20 Apr 2026 13:09:13 -0400","from mx-prod-int-01.mail-002.prod.us-west-2.aws.redhat.com\n (mx-prod-int-01.mail-002.prod.us-west-2.aws.redhat.com [10.30.177.4])\n (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)\n key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest\n SHA256)\n (No client certificate requested)\n by mx-prod-mc-08.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS\n id 4F2EA1800348\n for <gcc-patches@gcc.gnu.org>; Mon, 20 Apr 2026 17:09:12 +0000 (UTC)","from pdp-11.lan (unknown [10.22.81.30])\n by mx-prod-int-01.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTP\n id A67D23000C23; Mon, 20 Apr 2026 17:09:11 +0000 (UTC)"],"DKIM-Filter":["OpenDKIM Filter v2.11.0 sourceware.org 0B7A24AA54C6","OpenDKIM Filter v2.11.0 sourceware.org 555B34BC0577"],"DMARC-Filter":"OpenDMARC Filter v1.4.2 sourceware.org 555B34BC0577","ARC-Filter":"OpenARC Filter v1.0.0 sourceware.org 555B34BC0577","ARC-Seal":"i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1776704956; cv=none;\n b=JQdk7TO4u8/2yrVu65X8yBoPRx1oINY3UIAYjzRZItsbFtDrF9dLnvuK4tA3yi9q31WtwNFSqK8Lprlb9ezFocaeFgbRW/hbKLEAAboQlS5RkxglEoAlrkHvKOm6d6hpp2XJSa3vq9GXX/X8jlR8j8DESRiNFTCladPpR4wXHvo=","ARC-Message-Signature":"i=1; a=rsa-sha256; d=sourceware.org; s=key;\n t=1776704956; c=relaxed/simple;\n bh=EKbmnDjxKtM67NVohTUDcpYDJQkJTP2u3OkeH8ILdgk=;\n h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version;\n b=OlC0d/z9WNfVnm7FonA2vCAMS8Ea9uwCqze+PgbA3BPsdYFlRAEj2+YTlC95aMjTtpEM3UACIpQKmhRHgRAFV5Mh2brTQzlatCKLmU5SuWi959fjT9vzxGekFUCOjnXkYuvywFNM96aoOOx4Nwz8BeDUvh0LoFF54Lz0xDGBmyA=","ARC-Authentication-Results":"i=1; server2.sourceware.org","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com;\n s=mimecast20190719; t=1776704956;\n h=from:from:reply-to:subject:subject:date:date:message-id:message-id:\n to:to:cc:mime-version:mime-version:content-type:content-type:\n content-transfer-encoding:content-transfer-encoding;\n bh=1jZmWFwLJv8+HBd5WWXLjOs+kgQfEFre5SkRgB0g1fs=;\n b=F+PlyM51CnRY/+stQ6u7giXzMDk56HsPulikgacyEvyqXRbt4O7+ZLHL+5cM7rO6JazQ1r\n yZwIll0Q+HSHGStRUZZGK0dPfFO0QepY2ryojRaYJPh4kjjlkMh5dByoVnFMhvkepes7VP\n IDb+CvBdhblU/Mv2eYTI4pXnbToDMaI=","X-MC-Unique":"i8xThJWVPjyms38tR_OU0g-1","X-Mimecast-MFC-AGG-ID":"i8xThJWVPjyms38tR_OU0g_1776704952","From":"Marek Polacek <polacek@redhat.com>","To":"Jason Merrill <jason@redhat.com>,\n\tGCC Patches <gcc-patches@gcc.gnu.org>","Subject":"[PATCH] c++/reflection: improve diagnostic for dependent splices","Date":"Mon, 20 Apr 2026 13:08:59 -0400","Message-ID":"<20260420170859.370095-1-polacek@redhat.com>","MIME-Version":"1.0","X-Scanned-By":"MIMEDefang 3.4.1 on 10.30.177.4","X-Mimecast-Spam-Score":"0","X-Mimecast-MFC-PROC-ID":"6Mjl-CMdyENruyj2XV2B5uK8LUSuPpQOfUbFdMAQxQw_1776704952","X-Mimecast-Originator":"redhat.com","Content-Transfer-Encoding":"8bit","content-type":"text/plain; charset=\"US-ASCII\"; x-default=true","X-BeenThere":"gcc-patches@gcc.gnu.org","X-Mailman-Version":"2.1.30","Precedence":"list","List-Id":"Gcc-patches mailing list <gcc-patches.gcc.gnu.org>","List-Unsubscribe":"<https://gcc.gnu.org/mailman/options/gcc-patches>,\n <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>,\n <mailto:gcc-patches-request@gcc.gnu.org?subject=subscribe>","Errors-To":"gcc-patches-bounces~incoming=patchwork.ozlabs.org@gcc.gnu.org"},"content":"Tested dg.exp on x86_64-pc-linux-gnu, ok for trunk?\n\n-- >8 --\nIn the parser we've changed the \"not usable in a splice\" error messages\nto the more helpful \"expected a reflection of ...\", but tsubst_splice_scope\nstill uses the former.  This patch updates the diagnostic there as well.\nLet's also teach inform_tree_category about concepts and alias templates\nnow that a testcase exercises them.\n\ngcc/cp/ChangeLog:\n\n\t* error.cc (inform_tree_category): Also print concept and alias\n\ttemplate.\n\t* pt.cc (tsubst_splice_scope): Reword the diagnostic messages.\n\tCall inform_tree_category.\n\ngcc/testsuite/ChangeLog:\n\n\t* g++.dg/reflect/ns5.C: Adjust expected diagnostics.\n\t* g++.dg/reflect/type9.C: Likewise.\n---\n gcc/cp/error.cc                      |  4 +++\n gcc/cp/pt.cc                         | 16 ++++++----\n gcc/testsuite/g++.dg/reflect/ns5.C   | 41 ++++++++++++++++++--------\n gcc/testsuite/g++.dg/reflect/type9.C | 44 +++++++++++++++++++---------\n 4 files changed, 72 insertions(+), 33 deletions(-)\n\n\nbase-commit: 8e6b7c97232489557e376bdc134ad69aaeb35794","diff":"diff --git a/gcc/cp/error.cc b/gcc/cp/error.cc\nindex e7121dc1017..2ea9d1a7bcd 100644\n--- a/gcc/cp/error.cc\n+++ b/gcc/cp/error.cc\n@@ -4013,12 +4013,16 @@ inform_tree_category (tree t)\n     inform (loc, \"but %qE is a function template\", t);\n   else if (DECL_CLASS_TEMPLATE_P (t))\n     inform (loc, \"but %qE is a class template\", t);\n+  else if (DECL_ALIAS_TEMPLATE_P (t))\n+    inform (loc, \"but %qE is an alias template\", t);\n   else if (variable_template_p (t))\n     inform (loc, \"but %qE is a variable template\", t);\n   else if (TREE_CODE (t) == NAMESPACE_DECL)\n     inform (loc, \"but %qE is a namespace\", t);\n   else if (TREE_CODE (t) == CONST_DECL && !DECL_TEMPLATE_PARM_P (t))\n     inform (loc, \"but %qE is an enumerator\", t);\n+  else if (concept_definition_p (t))\n+    inform (loc, \"but %qE is a concept\", t);\n }\n \n /* Disable warnings about missing quoting in GCC diagnostics for\ndiff --git a/gcc/cp/pt.cc b/gcc/cp/pt.cc\nindex 2cf14e2c801..13153a7c179 100644\n--- a/gcc/cp/pt.cc\n+++ b/gcc/cp/pt.cc\n@@ -16899,21 +16899,25 @@ tsubst_splice_scope (tree t, tree args, tsubst_flags_t complain, tree in_decl)\n   tree r = tsubst (SPLICE_SCOPE_EXPR (t), args, complain, in_decl);\n   if (r == error_mark_node)\n     return r;\n+  const bool type_p = SPLICE_SCOPE_TYPE_P (t);\n   if (dependent_splice_p (r))\n-    return make_splice_scope (r, SPLICE_SCOPE_TYPE_P (t));\n-  if (SPLICE_SCOPE_TYPE_P (t) && ctad_template_p (r))\n+    return make_splice_scope (r, type_p);\n+  if (type_p && ctad_template_p (r))\n     r = make_template_placeholder (r);\n-  if (SPLICE_SCOPE_TYPE_P (t)\n+  if (type_p\n       ? !valid_splice_type_p (r)\n       : !valid_splice_scope_p (r))\n     {\n       if (complain & tf_error)\n \t{\n \t  const location_t loc = EXPR_LOCATION (SPLICE_SCOPE_EXPR (t));\n-\t  if (SPLICE_SCOPE_TYPE_P (t))\n-\t    error_at (loc, \"%qE is not usable in a splice type\", r);\n+\t  auto_diagnostic_group d;\n+\t  if (type_p)\n+\t    error_at (loc, \"expected a reflection of a type\");\n \t  else\n-\t    error_at (loc, \"%qE is not usable in a splice scope\", r);\n+\t    error_at (loc, \"expected a reflection of a class, namespace, or \"\n+\t\t      \"enumeration\");\n+\t  inform_tree_category (r);\n \t}\n       return error_mark_node;\n     }\ndiff --git a/gcc/testsuite/g++.dg/reflect/ns5.C b/gcc/testsuite/g++.dg/reflect/ns5.C\nindex 236b2927453..eb75481d9f1 100644\n--- a/gcc/testsuite/g++.dg/reflect/ns5.C\n+++ b/gcc/testsuite/g++.dg/reflect/ns5.C\n@@ -5,12 +5,16 @@ using info = decltype(^^void);\n \n template<typename>\n void foo () { }\n+template<typename>\n+void foo2 () { }\n void bar () { }\n namespace N { }\n namespace M = N;\n template<typename T>\n T vt{};\n template<typename T>\n+T vt2{};\n+template<typename T>\n concept C = true;\n static int i;\n enum E { X };\n@@ -20,23 +24,34 @@ struct D { static T di; };\n template<typename T>\n using Z = D<T>;\n \n-template<info R> void fn1 () { typename [:R:]::X x; }\t// { dg-error \"not usable in a splice scope\" }\n-template<info R> void fn2 () { typename [:R:]::X x; }   // { dg-error \"not usable in a splice scope\" }\n-template<info R> void fn3 () { typename [:R:]::X x; }   // { dg-error \"not usable in a splice scope\" }\n-template<info R> void fn4 () { typename [:R:]::X x; }   // { dg-error \"not usable in a splice scope\" }\n-template<info R> void fn5 () { typename [:R:]::X x; }   // { dg-error \"not usable in a splice scope\" }\n-template<info R> void fn6 () { typename [:R:]::X x; }   // { dg-error \"not usable in a splice scope\" }\n-template<info R> void fn7 () { typename [:R:]::X x; }   // { dg-error \"not usable in a splice scope\" }\n-template<info R> void fn8 () { typename [:R:]::X x; }   // { dg-error \"not usable in a splice scope\" }\n-template<info R> void fn9 () { typename [:R:]::X x; }   // { dg-error \"not usable in a splice scope\" }\n-template<info R> void fn10 () { typename [:R:]::X x; }  // { dg-error \"not usable in a splice scope\" }\n-template<info R> void fn11 () { typename [:R:]::X x; }  // { dg-error \"not usable in a splice scope\" }\n+template<info R> void fn1 () { typename [:R:]::X x; }\t// { dg-error \"expected a reflection of a class, namespace, or enumeration\" }\n+// { dg-message \"but .foo<int>. is a function\" \"\" { target *-*-* } 7 }\n+template<info R> void fn2 () { typename [:R:]::X x; }   // { dg-error \"expected a reflection of a class, namespace, or enumeration\" }\n+// { dg-message \"but .foo2. is a function template\" \"\" { target *-*-* } 9 }\n+template<info R> void fn3 () { typename [:R:]::X x; }   // { dg-error \"expected a reflection of a class, namespace, or enumeration\" }\n+// { dg-message \"but .bar. is a function\" \"\" { target *-*-* } 10 }\n+template<info R> void fn4 () { typename [:R:]::X x; }   // { dg-error \"expected a reflection of a class, namespace, or enumeration\" }\n+// { dg-message \"but .vt<int>. is a variable\" \"\" { target *-*-* } 14 }\n+template<info R> void fn5 () { typename [:R:]::X x; }   // { dg-error \"expected a reflection of a class, namespace, or enumeration\" }\n+// { dg-message \"but .vt2<T>. is a variable template\" \"\" { target *-*-* } 16 }\n+template<info R> void fn6 () { typename [:R:]::X x; }   // { dg-error \"expected a reflection of a class, namespace, or enumeration\" }\n+// { dg-message \"but .C. is a concept\" \"\" { target *-*-* } 18 }\n+template<info R> void fn7 () { typename [:R:]::X x; }   // { dg-error \"expected a reflection of a class, namespace, or enumeration\" }\n+// { dg-message \"but .i. is a variable\" \"\" { target *-*-* } 19 }\n+template<info R> void fn8 () { typename [:R:]::X x; }   // { dg-error \"expected a reflection of a class, namespace, or enumeration\" }\n+// { dg-message \"but .X. is an enumerator\" \"\" { target *-*-* } 20 }\n+template<info R> void fn9 () { typename [:R:]::X x; }   // { dg-error \"expected a reflection of a class, namespace, or enumeration\" }\n+// { dg-message \"but .S::si. is a variable\" \"\" { target *-*-* } 21 }\n+template<info R> void fn10 () { typename [:R:]::X x; }  // { dg-error \"expected a reflection of a class, namespace, or enumeration\" }\n+// { dg-message \"but .D<int>::di. is a variable\" \"\" { target *-*-* } 23 }\n+template<info R> void fn11 () { typename [:R:]::X x; }  // { dg-error \"expected a reflection of a class, namespace, or enumeration\" }\n+// { dg-message \"but .Z. is an alias template\" \"\" { target *-*-* } 25 }\n \n template void fn1<^^foo<int>>(); // { dg-message \"required from here\" }\n-template void fn2<^^foo>();\t // { dg-message \"required from here\" }\n+template void fn2<^^foo2>();\t // { dg-message \"required from here\" }\n template void fn3<^^bar>();\t // { dg-message \"required from here\" }\n template void fn4<^^vt<int>>();  // { dg-message \"required from here\" }\n-template void fn5<^^vt>();\t // { dg-message \"required from here\" }\n+template void fn5<^^vt2>();\t // { dg-message \"required from here\" }\n template void fn6<^^C>();\t // { dg-message \"required from here\" }\n template void fn7<^^i>();\t // { dg-message \"required from here\" }\n template void fn8<^^X>();\t // { dg-message \"required from here\" }\ndiff --git a/gcc/testsuite/g++.dg/reflect/type9.C b/gcc/testsuite/g++.dg/reflect/type9.C\nindex 2d0409e4b86..99c6fd2781b 100644\n--- a/gcc/testsuite/g++.dg/reflect/type9.C\n+++ b/gcc/testsuite/g++.dg/reflect/type9.C\n@@ -5,12 +5,16 @@ using info = decltype(^^void);\n \n template<typename>\n void foo () { }\n+template<typename>\n+void foo2 () { }\n void bar () { }\n namespace N { }\n namespace M = N;\n template<typename T>\n T vt{};\n template<typename T>\n+T vt2{};\n+template<typename T>\n concept C = true;\n static int i;\n enum E { X };\n@@ -20,27 +24,39 @@ struct D { static T di; };\n template<typename T>\n using Z = D<T>;\n \n-template<info R> void fn1 () { int n = typename [:R:](42); } // { dg-error \"not usable in a splice type\" }\n-template<info R> void fn2 () { int n = typename [:R:](42); } // { dg-error \"not usable in a splice type\" }\n-template<info R> void fn3 () { int n = typename [:R:](42); } // { dg-error \"not usable in a splice type\" }\n-template<info R> void fn4 () { int n = typename [:R:](42); } // { dg-error \"not usable in a splice type\" }\n-template<info R> void fn5 () { int n = typename [:R:](42); } // { dg-error \"not usable in a splice type\" }\n-template<info R> void fn6 () { int n = typename [:R:](42); } // { dg-error \"not usable in a splice type\" }\n-template<info R> void fn7 () { int n = typename [:R:](42); } // { dg-error \"not usable in a splice type\" }\n-template<info R> void fn8 () { int n = typename [:R:](42); } // { dg-error \"not usable in a splice type\" }\n-template<info R> void fn9 () { int n = typename [:R:](42); } // { dg-error \"not usable in a splice type\" }\n-template<info R> void fn10 () { int n = typename [:R:](42); } // { dg-error \"not usable in a splice type\" }\n-template<info R> void fn11 () { int n = typename [:R:](42); } // { dg-error \"not usable in a splice type\" }\n-template<info R> void fn12 () { int n = typename [:R:](42); } // { dg-error \"not usable in a splice type\" }\n+template<info R> void fn1 () { int n = typename [:R:](42); } // { dg-error \"expected a reflection of a type\" }\n+// { dg-message \"but .foo<int>. is a function\" \"\" { target *-*-* } 7 }\n+template<info R> void fn2 () { int n = typename [:R:](42); } // { dg-error \"expected a reflection of a type\" }\n+// { dg-message \"but .foo2. is a function template\" \"\" { target *-*-* } 9 }\n+template<info R> void fn3 () { int n = typename [:R:](42); } // { dg-error \"expected a reflection of a type\" }\n+// { dg-message \"but .N. is a namespace\" \"\" { target *-*-* } 11 }\n+template<info R> void fn4 () { int n = typename [:R:](42); } // { dg-error \"expected a reflection of a type\" }\n+// { dg-message \"but .M. is a namespace\" \"\" { target *-*-* } 12 }\n+template<info R> void fn5 () { int n = typename [:R:](42); } // { dg-error \"expected a reflection of a type\" }\n+// { dg-message \"but .bar. is a function\" \"\" { target *-*-* } 10 }\n+template<info R> void fn6 () { int n = typename [:R:](42); } // { dg-error \"expected a reflection of a type\" }\n+// { dg-message \"but .vt<int>. is a variable\" \"\" { target *-*-* } 14 }\n+template<info R> void fn7 () { int n = typename [:R:](42); } // { dg-error \"expected a reflection of a type\" }\n+// { dg-message \"but .vt2<T>. is a variable template\" \"\" { target *-*-* } 16 }\n+template<info R> void fn8 () { int n = typename [:R:](42); } // { dg-error \"expected a reflection of a type\" }\n+// { dg-message \"but .C. is a concept\" \"\" { target *-*-* } 18 }\n+template<info R> void fn9 () { int n = typename [:R:](42); } // { dg-error \"expected a reflection of a type\" }\n+// { dg-message \"but .i. is a variable\" \"\" { target *-*-* } 19 }\n+template<info R> void fn10 () { int n = typename [:R:](42); } // { dg-error \"expected a reflection of a type\" }\n+// { dg-message \"but .X. is an enumerator\" \"\" { target *-*-* } 20 }\n+template<info R> void fn11 () { int n = typename [:R:](42); } // { dg-error \"expected a reflection of a type\" }\n+// { dg-message \"but .S::si. is a variable\" \"\" { target *-*-* } 21 }\n+template<info R> void fn12 () { int n = typename [:R:](42); } // { dg-error \"expected a reflection of a type\" }\n+// { dg-message \"but .D<int>::di. is a variable\" \"\" { target *-*-* } 23 }\n template<info R> void fn13 () { int n = typename [:R:](42); } // { dg-error \"class template argument deduction failed|no matching\" }\n \n template void fn1<^^foo<int>>();  // { dg-message \"required from here\" }\n-template void fn2<^^foo>();\t  // { dg-message \"required from here\" }\n+template void fn2<^^foo2>();\t  // { dg-message \"required from here\" }\n template void fn3<^^N>();\t  // { dg-message \"required from here\" }\n template void fn4<^^M>();\t  // { dg-message \"required from here\" }\n template void fn5<^^bar>();\t  // { dg-message \"required from here\" }\n template void fn6<^^vt<int>>();\t  // { dg-message \"required from here\" }\n-template void fn7<^^vt>();\t  // { dg-message \"required from here\" }\n+template void fn7<^^vt2>();\t  // { dg-message \"required from here\" }\n template void fn8<^^C>();\t  // { dg-message \"required from here\" }\n template void fn9<^^i>();\t  // { dg-message \"required from here\" }\n template void fn10<^^X>();\t  // { dg-message \"required from here\" }\n","prefixes":[]}