Assuming that all functions share the same return type, is it valid to call each one by a "generic" function pointer, that is declared with empty parentheses (so it does not specify its arguments)?
Here is an example code, that illustrates it:
#include <stdio.h>
void fun1(void)
{
printf("fun1\n");
}
void fun2(int a)
{
printf("fun2: %d\n", a);
}
void fun3(int a, int b)
{
printf("fun3: %d %d\n", a, b);
}
int main(void)
{
void (*pf)(); // pseudo-generic function pointer
pf = fun1;
pf();
pf = fun2;
pf(0);
pf = fun3;
pf(1, 2);
return 0;
}