OSDN Git Service

PR c++/21495
[pf3gnuchains/gcc-fork.git] / gcc / cp / decl.c
index 529cfd5..eb8db91 100644 (file)
@@ -7002,30 +7002,7 @@ grokdeclarator (const cp_declarator *declarator,
       else
        {
          if (decl_context == FIELD)
-           {
-             tree tmp = NULL_TREE;
-             int op = 0;
-
-             if (declarator)
-               {
-                 /* Avoid trying to get an operand off an identifier node.  */
-                 if (declarator->kind != cdk_id)
-                   tmp = declarator->declarator->u.id.unqualified_name;
-                 else
-                   tmp = declarator->u.id.unqualified_name;
-                 op = IDENTIFIER_OPNAME_P (tmp);
-                 if (IDENTIFIER_TYPENAME_P (tmp))
-                   {
-                     if (is_typename_at_global_scope (tmp))
-                       name = IDENTIFIER_POINTER (tmp);
-                     else
-                       name = "<invalid operator>";
-                   }
-               }
-             error ("storage class specified for %s %qs",
-                    op ? "member operator" : "field",
-                    name);
-           }
+           error ("storage class specified for %qs", name);
          else
            {
              if (decl_context == PARM || decl_context == CATCHPARM)