File "test.cc" demonstrating a bug in gcc 2.95 on SCO 5.0.5a
Alexandre Oliva
oliva@lsd.ic.unicamp.br
Thu Jan 6 13:07:00 GMT 2000
On Jan 6, 2000, "Yeracaris, Anthony" <Anthony.Yeracaris@tfn.com> wrote:
> * Note that because BadCallT.call is declared with an `extern "C"'
> * linkage specification, the compiler is supposed to declare the
> * function as able to take any arguments (much like OkayCallT, which
> * works as expected). This error occurs even if the
> * -fno-strict-prototype switch is used.
Nope, extern "C" doesn't modify the language, just the linkage of the
function. The function is declared to take no arguments, and gcc is
correct to complain about this. It will probably compile with
-fpermissive, that's provided for backward compatibility, but this
doesn't make the code correct.
--
Alexandre Oliva http://www.ic.unicamp.br/~oliva IC-Unicamp, Bra[sz]il
oliva@{lsd.ic.unicamp.br,guarana.{org,com}} aoliva@{acm,computer}.org
oliva@{gnu.org,kaffe.org,{egcs,sourceware}.cygnus.com,samba.org}
** I may forward mail about projects to mailing lists; please use them
More information about the Gcc-bugs
mailing list