From: Paolo Carlini Date: Tue, 28 Aug 2007 16:41:56 +0000 (+0000) Subject: re PR c++/33209 (Broken diagnostic: 'template_type_parm' not supported by dump_expr) X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=0a8fc2475a662ae69dbc0e8d964fe9489a595fde;p=gcc.git re PR c++/33209 (Broken diagnostic: 'template_type_parm' not supported by dump_expr) /cp 2007-08-28 Paolo Carlini PR c++/33209 * error.c (dump_expr): Deal with TEMPLATE_TYPE_PARM and BOUND_TEMPLATE_TEMPLATE_PARM. /testsuite 2007-08-28 Paolo Carlini PR c++/33209 * g++.dg/template/error29.C: New. From-SVN: r127866 --- diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog index f612c9cb9d6..c6b2aaf8265 100644 --- a/gcc/cp/ChangeLog +++ b/gcc/cp/ChangeLog @@ -1,3 +1,9 @@ +2007-08-28 Paolo Carlini + + PR c++/33209 + * error.c (dump_expr): Deal with TEMPLATE_TYPE_PARM and + BOUND_TEMPLATE_TEMPLATE_PARM. + 2007-08-28 Jakub Jelinek PR c++/32596 diff --git a/gcc/cp/error.c b/gcc/cp/error.c index 90b95c08cac..d6675f0102e 100644 --- a/gcc/cp/error.c +++ b/gcc/cp/error.c @@ -2049,6 +2049,11 @@ dump_expr (tree t, int flags) pp_id_expression (cxx_pp, t); break; + case TEMPLATE_TYPE_PARM: + case BOUND_TEMPLATE_TEMPLATE_PARM: + dump_type (t, flags); + break; + /* This list is incomplete, but should suffice for now. It is very important that `sorry' does not call `report_error_function'. That could cause an infinite loop. */ diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 0bbe27a9bef..6254d202c49 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,8 @@ +2007-08-28 Paolo Carlini + + PR c++/33209 + * g++.dg/template/error29.C: New. + 2007-08-28 Jakub Jelinek PR c++/32596 diff --git a/gcc/testsuite/g++.dg/template/error29.C b/gcc/testsuite/g++.dg/template/error29.C new file mode 100644 index 00000000000..2e2291d7e87 --- /dev/null +++ b/gcc/testsuite/g++.dg/template/error29.C @@ -0,0 +1,5 @@ +// PR c++/33209 + +template void foo(int, T::x); // { dg-error "T::x" } + +template class T> void foo2(int, T::x); // { dg-error "T::x" }