This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c/12466] New: -Wold-style-definition incorrectly warns with ellipsises.
- From: "kcook at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 30 Sep 2003 17:43:44 -0000
- Subject: [Bug c/12466] New: -Wold-style-definition incorrectly warns with ellipsises.
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
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