The right-left rule
John Kessenich
jk at hpfelg.HP.COM
Fri Jul 20 09:18:56 AEST 1990
>Problem is how do you declare a pointer to an array of pointers of functions
>returning void?
Lets see,
void (*state_variable)();
read in precedence order would be a pointer to function returning void.
To get a pointer to an array of these you need a pointer to one of these,
void (**state_variable)();
Reading in precedence order gives a pointer to a pointer to a function
that returns void, which is equivalent to saying a pointer to an array
of functions returning void.
To get an array of pointers to functions returning void, just use
void (*state_variable[SIZE])();
--------------
John Kessenich
More information about the Comp.lang.c
mailing list