Add gcc.dg/warn-1.c

From-SVN: r58549
This commit is contained in:
Mike Stump 2002-10-26 01:15:16 +00:00 committed by Mike Stump
parent e93ee6440d
commit f0dd122b47
2 changed files with 20 additions and 0 deletions

View File

@ -1,3 +1,7 @@
2002-10-25 Mike Stump <mrs@apple.com>
* gcc.dg/warn-1.c: New test.
2002-10-25 Zack Weinberg <zack@codesourcery.com>
* g++.dg/template/typename3.C: New test.

View File

@ -0,0 +1,16 @@
/* The compiler used to say passing arg 0 of, which is wrong. */
/* Radar 3069179 */
/* { dg-options "-O3" } */
static void foo (p)
int p;
{ /* { dg-warning "passing arg of" } */
}
static void bar (void)
{
void *vp;
foo (vp); /* { dg-warning "" } */
}