Is it possible to declare function pointer in xC?
I have the following code:
Code: Select all
typedef struct {
ComType retType;
char * unsafe name;
uint8 numOfArgs;
ComArg * unsafe args;
void (* unsafe handler)(ComContext & ctx, client interface ComRxIf rxIf, client interface ComTxIf txIf);
} ComFunc;
Code: Select all
.././inc/Shell.h:45:5: error: cannot declare pointer to function
void (* unsafe handler)(ComContext & ctx, client interface ComRxIf rxIf, client interface ComTxIf txIf);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~