Thread View: gnu.gcc.bug
1 messages
1 total messages
Started by Jason Merrill
Sat, 31 Oct 1992 22:48
built-in recognition bug in gcc 2.2.2
Author: Jason Merrill
Date: Sat, 31 Oct 1992 22:48
Date: Sat, 31 Oct 1992 22:48
39 lines
1401 bytes
1401 bytes
When building the GNU m4-1.0 distribution, the obstack.c compile died with
the error
obstack.c:26: conflicting types for `abort'
<built-in>:0: previous declaration of `abort'
Now, according to c-decl.c,
...
else if (TREE_CODE (olddecl) == FUNCTION_DECL
&& DECL_BUILT_IN (olddecl))
{
if (!TREE_PUBLIC (newdecl))
{
...
}
else if (!types_match)
warning_with_decl (newdecl, "conflicting types for built-in function `%s'");
}
...
So it seems to me this should be a warning, not an error. So I stepped
through here with gdb, and found that although olddecl->decl->filename was
set to "<built-in>", olddecl->decl->bit_field_flag was 0, indicating that
the function was not built in...
Here is an input file which reproduces the bug:
-----
int abort();
main()
{
}
-----
--
Jason Merrill
jason@jarthur.claremont.edu
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads