Commit 6809f4b5 by Paolo Carlini Committed by Paolo Carlini

re PR c++/45665 (ICE: tree check: expected class 'type', have 'exceptional'…

re PR c++/45665 (ICE: tree check: expected class 'type', have 'exceptional' (error_mark) in grokdeclarator, at cp/decl.c:8797 on invalid code)

/cp
2010-09-15  Paolo Carlini  <paolo.carlini@oracle.com>

	PR c++/45665
	* decl.c (grokdeclarator): Check build_memfn_type return value
	for error_mark_node.

/testsuite
2010-09-15  Paolo Carlini  <paolo.carlini@oracle.com>

	PR c++/45665
	* g++.dg/template/crash103.C: New.

From-SVN: r164299
parent 10937190
2010-09-15 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/45665
* decl.c (grokdeclarator): Check build_memfn_type return value
for error_mark_node.
2010-09-13 Rodrigo Rivas Costa <rodrigorivascosta@gmail.com>
* semantics.c (finish_for_stmt): Always test flag_new_for_scope.
......
......@@ -8762,6 +8762,8 @@ grokdeclarator (const cp_declarator *declarator,
type = build_memfn_type (type,
declarator->u.pointer.class_type,
memfn_quals);
if (type == error_mark_node)
return error_mark_node;
memfn_quals = TYPE_UNQUALIFIED;
}
......
2010-09-15 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/45665
* g++.dg/template/crash103.C: New.
2010-09-15 Nicola Pero <nicola.pero@meta-innovation.com>
Merge from 'apple/trunk' branch on FSF servers.
......
// PR c++/45665
template < typename > struct S;
void (S <0>::*ptr) (); // { dg-error "type" }
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