This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: A user's experiences with GCC-3.4 snapshots


On Tue, Sep 16, 2003 at 02:31:58PM -0500, Art Haas wrote:
> $ cat try.c
> #include <stdio.h>
> int main() { extern void *setproctitle(); if(&setproctitle) return(0); else return(1); }

This is not a valid way to test the existence of a function, and GCC is
correct.  You are declaring that there is an external symbol named
setproctitle, and asking for its address.  The C standard guarantees
that the address of a function will never compare equal to NULL.

So Perl needs to be fixed.

-- 
Daniel Jacobowitz
MontaVista Software                         Debian GNU/Linux Developer


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]