------- Additional Comments From rguenth at gcc dot gnu dot org 2005-08-10 08:37 ------- g++ (GCC) 4.0.2 20050728 does not ICE for me on the reduced testcase, but instead mainline does with a slightly different ICE:
pr23307.ii:5: internal compiler error: in cp_parser_template_id, at cp/parser.c:8660 #0 fancy_abort (file=0xc417b2 "../../gcc/gcc/cp/parser.c", line=8660, function=0xc43a64 "cp_parser_template_id") at diagnostic.c:590 #1 0x00000000004f4c03 in cp_parser_template_id (parser=0x2a958963c0, template_keyword_p=0 '\0', check_dependency_p=1 '\001', is_declaration=0 '\0') at parser.c:8658 #2 0x00000000004f9609 in cp_parser_class_name (parser=0x2a958963c0, typename_keyword_p=0 '\0', template_keyword_p=0 '\0', tag_type=none_type, check_dependency_p=1 '\001', class_head_p=0 '\0', is_declaration=0 '\0') at parser.c:12521 I question the use of asserts in paths of the compiler where we might deal with errorneus input. Why not return error_mark_node instead? Which fixes the ICE btw. -- I'll prepare a patch. Richard. -- What |Removed |Added ---------------------------------------------------------------------------- AssignedTo|unassigned at gcc dot gnu |rguenth at gcc dot gnu dot |dot org |org Status|UNCONFIRMED |ASSIGNED Ever Confirmed| |1 Keywords| |ice-on-invalid-code Known to fail| |4.1.0 Known to work| |4.0.2 Last reconfirmed|0000-00-00 00:00:00 |2005-08-10 08:37:14 date| | http://gcc.gnu.org/bugzilla/show_bug.cgi?id=23307