On 05/24/2011 05:59 AM, Jason Merrill wrote:
It occurred to me today that I could use current_class_name rather than TYPE_IDENTIFIER (current_class_type).
Thus I suppose the below is also ok and obvious? To be safe, I'm testing it on x86_64-linux.

Paolo.

//////////////////////
2011-05-24  Paolo Carlini  <paolo.carl...@oracle.com>

        * decl.c (grokdeclarator): Use current_class_name.
Index: decl.c
===================================================================
--- decl.c      (revision 174105)
+++ decl.c      (working copy)
@@ -9910,7 +9910,7 @@ grokdeclarator (const cp_declarator *declarator,
               instantiation made the field's type be incomplete.  */
            if (current_class_type
                && TYPE_NAME (current_class_type)
-               && IDENTIFIER_TEMPLATE (TYPE_IDENTIFIER (current_class_type))
+               && IDENTIFIER_TEMPLATE (current_class_name)
                && declspecs->type
                && declspecs->type == type)
              error ("  in instantiation of template %qT",

Reply via email to