This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c/17573] New: redefinition of builtin generates error when K&R fn def used
- From: "bowdidge at apple dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 20 Sep 2004 22:00:25 -0000
- Subject: [Bug c/17573] New: redefinition of builtin generates error when K&R fn def used
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
The following code generates an error if a function is defined in K&R style, but not if the function is
defined in ANSI C style:
extern float dremf ( float, float );
float
dremf(x, y)
float x;
float y;
{
return 1.0;
}
On Apple's gcc-3.5-based compilers, the code generates an error or warning with the K&R C definition,
but generates no error with the ANSI C function declaration. The problem is reproducible on at least
the 9/2 mainline, also with powerpc-apple-darwin.
--
Summary: redefinition of builtin generates error when K&R fn def
used
Product: gcc
Version: 4.0.0
Status: UNCONFIRMED
Severity: normal
Priority: P2
Component: c
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: bowdidge at apple dot com
CC: gcc-bugs at gcc dot gnu dot org
GCC build triplet: powerpc-apple-darwin
GCC host triplet: powerpc-apple-darwin
GCC target triplet: powerpc-apple-darwin
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17573