Commit cc79e34f by Zack Weinberg Committed by Zack Weinberg

* gcc.dg/builtins-30.c: Move dg-warning marks to the proper lines.

From-SVN: r76482
parent 72afd981
2004-01-23 Zack Weinberg <zack@codesourcery.com>
* gcc.dg/builtins-30.c: Move dg-warning marks to the proper lines.
2004-01-24 Joseph S. Myers <jsm@polyomino.org.uk>
* gcc.dg/c90-array-lval-7.c, gcc.dg/c99-array-lval-7.c: New tests.
......
......@@ -7,21 +7,21 @@ extern double strtod (const char *, char **);
/* A built-in function may be overridden by an old-style definition
specifying too few arguments... */
double nan ()
{
return strtod ("nan", 0); /* { dg-warning "shadowing built-in" } */
{ /* { dg-warning "shadowing built-in" } */
return strtod ("nan", 0);
}
/* the right number, but the wrong type, arguments... */
float nanf (foo)
int foo UNUSED;
int foo UNUSED; /* { dg-warning "shadowing built-in" } */
{
return strtod ("nan", 0); /* { dg-warning "shadowing built-in" } */
return strtod ("nan", 0);
}
/* or too many arguments. */
long double nanl (foo, bar)
const char *foo UNUSED;
const char *foo UNUSED; /* { dg-warning "shadowing built-in" } */
int bar UNUSED;
{
return strtod ("nan", 0); /* { dg-warning "shadowing built-in" } */
return strtod ("nan", 0);
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment