re PR middle-end/27428 (ICE with goto in erroneous code)

PR middle-end/27428
	* c-lex.c (c_lex_with_flags) <CPP_N_INVALID>: Increment errorcount
	to indicate the cpplib has issued an error message for us.

	* gcc.dg/pr27428-1.c: New test case.

From-SVN: r115080
This commit is contained in:
Roger Sayle 2006-06-29 21:57:23 +00:00 committed by Roger Sayle
parent f8c2645c2d
commit 8646f3df36
4 changed files with 21 additions and 0 deletions

View File

@ -1,3 +1,9 @@
2006-06-29 Roger Sayle <roger@eyesopen.com>
PR middle-end/27428
* c-lex.c (c_lex_with_flags) <CPP_N_INVALID>: Increment errorcount
to indicate the cpplib has issued an error message for us.
2006-06-29 Asher Langton <langton2@llnl.gov>
PR target/25765

View File

@ -364,6 +364,7 @@ c_lex_with_flags (tree *value, location_t *loc, unsigned char *cpp_flags)
case CPP_N_INVALID:
/* cpplib has issued an error. */
*value = error_mark_node;
errorcount++;
break;
case CPP_N_INTEGER:

View File

@ -1,3 +1,8 @@
2006-06-29 Roger Sayle <roger@eyesopen.com>
PR middle-end/27428
* gcc.dg/pr27428-1.c: New test case.
2006-06-29 Mike Stump <mrs@apple.com>
* gcc.dg/compat/struct-layout-1_generate.c: Don't use common

View File

@ -0,0 +1,9 @@
/* { dg-do compile } */
/* { dg-options "-O2" } */
void foo()
{
goto L;
if (0..) { L: ; } // { dg-error "too many decimal points" }
}