Array of pointers to functions

Andrew Koenig ark at alice.UUCP
Mon Apr 22 06:04:47 AEST 1985


> A programmer here was wondering how you would declare an
> array of pointers to functions returning pointers to
> integers.  I've been able to generate code producing a
> single pointer to a function returning a pointer to an
> integer, as

> 	int *(*fp_ret_ip)();

> but I've been unable to get the C compiler to accept an
> array version of this.

Declare 'em like you use 'em:

	int *(*fp_ret_ip[10])();

This works just fine on my compiler; if it doesn't on yours,
maybe your compiler is broken.



More information about the Comp.lang.c mailing list