[Bug c/12466] New: -Wold-style-definition incorrectly warns with ellipsises.
kcook at gcc dot gnu dot org
gcc-bugzilla@gcc.gnu.org
Tue Sep 30 17:59:00 GMT 2003
PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=12466
Summary: -Wold-style-definition incorrectly warns with
ellipsises.
Product: gcc
Version: 3.4
Status: UNCONFIRMED
Severity: normal
Priority: P2
Component: c
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: kcook at gcc dot gnu dot org
CC: gcc-bugs at gcc dot gnu dot org
In attempting to compile GCC with -Wold-style-definition, I ran into many of the
following errors, which are false positives due to the ellipsis.
>From gengtype.c:70
/* Wrapper for xvasprintf. */
char *
xasprintf (const char *format, ...)
{
char *result;
va_list ap;
va_start (ap, format);
xvasprintf (&result, format, ap);
va_end (ap);
return result;
}
This warns with:
../../gcc-snapshot/gcc/gengtype.c: In function `xasprintf':
../../gcc-snapshot/gcc/gengtype.c:73: warning: old-style parameter declaration
Reduced Testcase and suggested patch coming shortly
More information about the Gcc-bugs
mailing list