decl-2.c: Add extra line breaks.

* gcc.dg/decl-2.c:  Add extra line breaks.  That way we can verify
	that diagnotics refer to correct token.
	* gcc.dg/unused-3.c: Likewise.

From-SVN: r96339
This commit is contained in:
Per Bothner 2005-03-12 07:40:35 -08:00 committed by Per Bothner
parent 7532884955
commit 7c6d34c729
3 changed files with 19 additions and 3 deletions

View File

@ -15,6 +15,12 @@
* gcc.dg/vmx/darwin-abi-3.c: Delete.
2005-03-11 Per Bothner <per@bothner.com>
* gcc.dg/decl-2.c: Add extra line breaks. That way we can verify
that diagnotics refer to correct token.
* gcc.dg/unused-3.c: Likewise.
2005-03-11 Per Bothner <per@bothner.com>
* gcc.dg/cpp/direct2.c: With new lexer changes, error "before string

View File

@ -1,10 +1,16 @@
/* PR c/7411 */
/* Contributed by Christian Ehrhardt */
/* Added extra line-breaks to check that diagnostics refer to correct token.
--Per Bothner. */
/* { dg-do compile } */
void foo(void)
{
char c; /* { dg-error "previous declaration" } */
char
c /* { dg-error "previous declaration" } */
;
int i;
int c = i; /* { dg-error "conflicting types" } */
int
c /* { dg-error "conflicting types" } */
= i;
}

View File

@ -1,10 +1,14 @@
/* Copyright (C) 2000 Free Software Foundation. */
/* Added extra line-breaks to check that diagnostics refer to correct token.
--Per Bothner. */
/* { dg-do compile } */
/* { dg-options "-Wunused" } */
typedef short unused_type __attribute__ ((unused));
main ()
{
short x; /* { dg-warning "unused variable" "unused variable warning" } */
short
x /* { dg-warning "unused variable" "unused variable warning" } */
;
unused_type y;
}