Trying to call a function that gets used as an argument for another function, while passing it's own arguments. Example in pseudoish c++ code:
void function1(argument(x)) ///I believe this should be void function1(void(*argument)(int)), but i try to call it as *argument(); and that fails also
{
doStuff;
argument(x);
doMoreStuff;
}
void function2(int x)
{
int test;
test = x + 2;
doOtherStuffWithx;
}
int main()
{
int test = 1;
sample = function1(function2(test));
}
haven't been able to figure it out. Any help would be greatly appreciated.