Hello.
So I was making a structure where I wanted to declare a function, but then I notice that the code I would use in vanilla C is not working in RobotC. So code is fairly simple:
struct something
{
int (*func)(int a);
}
int FUNC(int a)
{
return a;
}
task main() {
something strc;
strc.func = FUNC;
}
but it happens to have lots of errors. Could you help me declare the function?
Thanks in advance.