array of pointer to function support in GNU C

Zoltán Kócsi zoltan@bendor.com.au
Fri Sep 17 06:25:00 GMT 2010


On Thu, 16 Sep 2010 00:50:07 -0700
J Decker <d3ck0r@gmail.com> wrote:

[...]

> > int main(void)
> > {
> >    void *(*func)(void **);
> >    func;
> strange that this does anything... since it also requires a pointer to
> a pointer...

I think the compiler is right: "func" is a pointer to a function.
Since the () operator (function call) is not used, it simply parses as
an expression without any side effect. Same as

char *x;

 x;

Zoltan



More information about the Gcc mailing list