aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--gcc/cp/ChangeLog2
-rw-r--r--gcc/cp/error.c2
2 files changed, 3 insertions, 1 deletions
diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog
index 2a6ec5d..fc9de2d 100644
--- a/gcc/cp/ChangeLog
+++ b/gcc/cp/ChangeLog
@@ -1,5 +1,7 @@
2009-06-24 Jason Merrill <jason@redhat.com>
+ * error.c (dump_decl): Do say "typedef" for the injected class name.
+
* pt.c (lookup_template_class): Use currently_open_class,
compare template args later.
diff --git a/gcc/cp/error.c b/gcc/cp/error.c
index 7be241d..98dacb1 100644
--- a/gcc/cp/error.c
+++ b/gcc/cp/error.c
@@ -862,7 +862,7 @@ dump_decl (tree t, int flags)
{
case TYPE_DECL:
/* Don't say 'typedef class A' */
- if (DECL_ARTIFICIAL (t))
+ if (DECL_ARTIFICIAL (t) && !DECL_SELF_REFERENCE_P (t))
{
if ((flags & TFF_DECL_SPECIFIERS)
&& TREE_CODE (TREE_TYPE (t)) == TEMPLATE_TYPE_PARM)