------- Comment #2 from pinskia at gcc dot gnu dot org 2008-12-31 23:08 -------
I think I have a simple parser fix for this.
Index: parser.c
===================================================================
--- parser.c (revision 142986)
+++ parser.c (working copy)
@@ -11537,7 +11537,11 @@ cp_parser_elaborated_type_specifier (cp_
type = make_typename_type (parser->scope, decl,
typename_type,
/*complain=*/tf_error);
- else
+ /* If the `typename' keyword is in effect and DECL is not a type decl.
Then
+ type is non existant. */
+ else if (tag_type == typename_type && TREE_CODE (decl) != TYPE_DECL)
+ type = NULL_TREE;
+ else
type = TREE_TYPE (decl);
}
But I need to check if we could get anything besides typedecl here really.
--
pinskia at gcc dot gnu dot org changed:
What |Removed |Added
----------------------------------------------------------------------------
Last reconfirmed|2008-12-27 01:29:47 |2008-12-31 23:08:25
date| |
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38638