This is the mail archive of the gcc-bugs@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]

Re: problem returning function pointers


On Mar 29, 2000, Ben Woodard <ben@valinux.com> wrote:

> For example I want to declare a function:

> void (*)(void *,const unsigned char*) to_ipaddr_funct((*fp)(void));

> but the compiler doesn't seem to like that

Sure, the syntax is incorrect.  It accepts the correct syntax:

void (*to_ipaddr_funct(int (*fp)(void)))(void *,const unsigned char*);

-- 
Alexandre Oliva    Enjoy Guaranį, see http://www.ic.unicamp.br/~oliva/
Cygnus Solutions, a Red Hat company        aoliva@{redhat, cygnus}.com
Free Software Developer and Evangelist    CS PhD student at IC-Unicamp
oliva@{lsd.ic.unicamp.br, gnu.org}   Write to mailing lists, not to me


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