This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/28261] [4.0/4.1/4.2 regression] ICE with enum in constructor definition
- From: "mmitchel at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 17 Oct 2006 22:43:47 -0000
- Subject: [Bug c++/28261] [4.0/4.1/4.2 regression] ICE with enum in constructor definition
- References: <bug-28261-1771@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #4 from mmitchel at gcc dot gnu dot org 2006-10-17 22:43 -------
Subject: Bug 28261
Author: mmitchel
Date: Tue Oct 17 22:43:37 2006
New Revision: 117835
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=117835
Log:
PR c++/28261
* parser.c (cp_lexer_next_token_is_decl_specifier_keyword): New
function.
(cp_parser_constructor_declarator_p): Use it.
(cp_parser_check_type_definition): Return a value indicating
whether or not the definition is valid.
(cp_parser_enum_specifier): Skip invalid enum definitions.
PR c++/28261
* g++.dg/parse/enum3.C: New test.
Added:
trunk/gcc/testsuite/g++.dg/parse/enum3.C
Modified:
trunk/gcc/cp/ChangeLog
trunk/gcc/cp/parser.c
trunk/gcc/testsuite/ChangeLog
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28261