Using FFF to stub functions that have function pointer parameter can cause problems when trying to stub them. Presented here is an example how to deal with this situation.
If you need to stub a function that has a function pointer parameter, e.g. something like:
/* timer.h */
typedef int timer_handle;
extern int timer_start(timer_handle handle, long delay, void (*cb_function) (int arg), int arg);
Then creating a fake like below will horribly fail when trying to compile because the FFF macro will internally expand into an illegal variable int (*)(int) arg2_val
.