20040910-1.c, [...]: Adjust expected messages for new parser.

* gcc.dg/20040910-1.c, gcc.dg/cpp/digraph2.c,
	gcc.dg/cpp/direct2.c, gcc.dg/cpp/direct2s.c,
	gcc.dg/cpp/separate-1.c, gcc.dg/noncompile/951123-1.c,
	gcc.dg/noncompile/971104-1.c, gcc.dg/noncompile/990416-1.c: Adjust
	expected messages for new parser.

From-SVN: r90128
This commit is contained in:
Joseph Myers 2004-11-05 16:43:49 +00:00 committed by Joseph Myers
parent 54f88091c5
commit 88876c7cb4
9 changed files with 24 additions and 16 deletions

View File

@ -1,3 +1,11 @@
2004-11-05 Joseph S. Myers <joseph@codesourcery.com>
* gcc.dg/20040910-1.c, gcc.dg/cpp/digraph2.c,
gcc.dg/cpp/direct2.c, gcc.dg/cpp/direct2s.c,
gcc.dg/cpp/separate-1.c, gcc.dg/noncompile/951123-1.c,
gcc.dg/noncompile/971104-1.c, gcc.dg/noncompile/990416-1.c: Adjust
expected messages for new parser.
2004-11-04 Mark Mitchell <mark@codesourcery.com>
* testsuite/g++.dg/ext/visibility/symbian1.C: New test.

View File

@ -1,2 +1,2 @@
/* Tests error recovery for invalid code. */
__attribute__((foo) int f (){} /* { dg-error "(parse|syntax) error before 'int'" } */
__attribute__((foo) int f (){} /* { dg-error "(parse error|syntax error|expected '\\)') before 'int'" } */

View File

@ -9,7 +9,7 @@
int main (int argc, char *argv[])
{
return 0;
%> /* { dg-error "(parse|syntax) error" } */
%> /* { dg-error "parse error|syntax error|expected" } */
/* Place this after main () so we get to test both the compiler above
and the preprocessor below. */

View File

@ -12,21 +12,21 @@
HASH include "somerandomfile" /*{ dg-error "stray" "non-include" }*/
/*{ dg-bogus "No such" "don't execute non-include" { target *-*-* } 13 }*/
int resync_parser_1; /*{ dg-error "parse|syntax" "" }*/
int resync_parser_1; /*{ dg-error "parse|syntax|expected" "" }*/
HASHINCLUDE <somerandomfile> /*{ dg-error "stray" "non-include 2" }*/
HASHINCLUDE <somerandomfile> /*{ dg-error "stray|expected" "non-include 2" }*/
/*{ dg-bogus "No such" "don't execute non-include 2" { target *-*-* } 17 }*/
int resync_parser_2;
void g1 ()
{
HASH define X 1 /* { dg-error "stray|undeclared|parse|syntax|for each" "# from macro" } */
HASH define X 1 /* { dg-error "stray|undeclared|parse|syntax|expected|for each" "# from macro" } */
int resync_parser_3;
}
void g2 ()
{
HASHDEFINE Y 1 /* { dg-error "stray|undeclared|parse|syntax|for each" "#define from macro" } */
HASHDEFINE Y 1 /* { dg-error "stray|undeclared|parse|syntax|expected|for each" "#define from macro" } */
int resync_parser_4;
}
@ -42,5 +42,5 @@ void f ()
#define slashstar /##*
#define starslash *##/
slashstar starslash /* { dg-error "(parse|syntax) error" "not a comment" } */
slashstar starslash /* { dg-error "parse error|syntax error|expected" "not a comment" } */
/* { dg-warning "does not give" "paste warning(s)" { target *-*-* } 45 } */

View File

@ -14,21 +14,21 @@
HASH include "somerandomfile" /*{ dg-error "stray" "non-include" }*/
/*{ dg-bogus "No such" "don't execute non-include" { target *-*-* } 15 }*/
int resync_parser_1; /*{ dg-error "parse|syntax" "" }*/
int resync_parser_1; /*{ dg-error "parse|syntax|expected" "" }*/
HASHINCLUDE <somerandomfile> /*{ dg-error "stray" "non-include 2" }*/
HASHINCLUDE <somerandomfile> /*{ dg-error "stray|expected" "non-include 2" }*/
/*{ dg-bogus "No such" "don't execute non-include 2" { target *-*-* } 18 }*/
int resync_parser_2;
void g1 ()
{
HASH define X 1 /* { dg-error "stray|undeclared|parse|syntax|for each" "# from macro" } */
HASH define X 1 /* { dg-error "stray|undeclared|parse|syntax|expected|for each" "# from macro" } */
int resync_parser_3;
}
void g2 ()
{
HASHDEFINE Y 1 /* { dg-error "stray|undeclared|parse|syntax|for each" "#define from macro" } */
HASHDEFINE Y 1 /* { dg-error "stray|undeclared|parse|syntax|expected|for each" "#define from macro" } */
int resync_parser_4;
}

View File

@ -8,8 +8,8 @@
#define FOO()
int FOO( /* { dg-error "(parse|syntax) error" "error on this line" } */
int FOO( /* { dg-error "parse error|syntax error|expected" "error on this line" } */
), bar;
int baz FOO /* { dg-error "(parse|syntax) error" "error on this line" } */
int baz FOO /* { dg-error "parse error|syntax error|expected" "error on this line" } */
; /* { dg-warning "no type or storage class" "warning on this line" } */

View File

@ -1,2 +1,2 @@
struct S { int a; int b[2]; };
struct S x = { 0, [0]; }; /* { dg-error "array index|near|(parse|syntax)" } */
struct S x = { 0, [0]; }; /* { dg-error "array index|near|parse|syntax|expected" } */

View File

@ -24,6 +24,6 @@ static void up(int sem){
printf("%s had processes sleeping on it!\n",
({ "MUTEX ", "BARB_SEM 1", "BARB_SEM 2", "CUST_SEM 1",
"CUST_SEM 2", "WAIT_SEM 1", "WAIT_SEM 2", "WAIT_SEM 3",
"WAIT_SEM 4"} /* { dg-error "(parse|syntax) error" } */
"WAIT_SEM 4"} /* { dg-error "parse error|syntax error|expected" } */
[( sb.sem_num )]) );
}

View File

@ -2,7 +2,7 @@ extern void *memcpy (void *, const void *, __SIZE_TYPE__);
typedef int word_type;
static void
copy_reg (unsigned int reg, frame_state *udata, /* { dg-error "parse|syntax" } */
copy_reg (unsigned int reg, frame_state *udata, /* { dg-error "parse|syntax|expected" } */
frame_state *target_udata)
{
word_type *preg = get_reg_addr (reg, udata, 0); /* { dg-error "undeclared|function|without a cast" } */