+1998-09-22 Benjamin Kosnik <bkoz@loony.cygnus.com>
+
+ * decl.c (make_typename_type): Move error to point where name
+ variable can be used by dump_type.
+
1998-09-22 Mark Mitchell <mark@markmitchell.com>
* decl.c (grokfndecl): Improve error-recovery.
fullname = name;
- if (TREE_CODE (context) == NAMESPACE_DECL)
- {
- /* We can get here from typename_sub0 in the explicit_template_type
- expansion. Just fail. */
- cp_error ("no class template named `%#T' in `%#T'",
- name, context);
- return error_mark_node;
- }
-
if (TREE_CODE (name) == TEMPLATE_ID_EXPR)
{
name = TREE_OPERAND (name, 0);
if (TREE_CODE (name) != IDENTIFIER_NODE)
my_friendly_abort (2000);
+ if (TREE_CODE (context) == NAMESPACE_DECL)
+ {
+ /* We can get here from typename_sub0 in the explicit_template_type
+ expansion. Just fail. */
+ cp_error ("no class template named `%#T' in `%#T'",
+ name, context);
+ return error_mark_node;
+ }
+
if (! uses_template_parms (context)
|| currently_open_class (context))
{