Commit 5cc66776 by Dodji Seketeli Committed by Dodji Seketeli

PR c++/51043 - ICE in LTO

	* cp-tree.h (TYPE_ALIAS_P, TYPE_TEMPLATE_INFO): Don't crash on
	NULL TYPE_NAME.

From-SVN: r181231
parent e7a82751
......@@ -41,6 +41,10 @@
2011-11-09 Dodji Seketeli <dodji@redhat.com>
PR c++/51043
* cp-tree.h (TYPE_ALIAS_P, TYPE_TEMPLATE_INFO): Don't crash on
NULL TYPE_NAME.
PR c++/51027
* parser.c (cp_parser_alias_declaration): Require ';' at the end
of the declaration.
......
......@@ -2552,6 +2552,7 @@ extern void decl_shadowed_for_var_insert (tree, tree);
another-type'. */
#define TYPE_ALIAS_P(NODE) \
(TYPE_P (NODE) \
&& TYPE_NAME (NODE) \
&& TYPE_DECL_ALIAS_P (TYPE_NAME (NODE)))
/* For a class type: if this structure has many fields, we'll sort them
......@@ -2612,7 +2613,7 @@ extern void decl_shadowed_for_var_insert (tree, tree);
? TEMPLATE_TEMPLATE_PARM_TEMPLATE_INFO (NODE) : \
((CLASS_TYPE_P (NODE) && !TYPE_ALIAS_P (NODE)) \
? CLASSTYPE_TEMPLATE_INFO (NODE) \
: (DECL_LANG_SPECIFIC (TYPE_NAME (NODE)) \
: ((TYPE_NAME (NODE) && DECL_LANG_SPECIFIC (TYPE_NAME (NODE))) \
? (DECL_TEMPLATE_INFO (TYPE_NAME (NODE))) \
: NULL_TREE))))
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment