Hi all, i have a certain certain command code that seems ambigues to me and I'm forced to use it. Can anyone explain the meaning of this particular line of code: ???
i'm having problem with comprehending the use "typedef" along with the entire function pointer...Code:
typedef void (*Function_Type)(ItemType &item);
my first inclination was that this is a pointer to a function which returns void and takes (ItemType &item) as an argument...??
and just for reference, I have a function that takes that same function pointer as an argument and inside calls another function whose (obviously) pointer to was passed in: for example
void traverse(Function_Type visit)
for(int i = 0; i < size; i++)
now, with all this said, i was trying to call the function "traverse()" but i'm always getting compiler errors, even when i try to use different way of expressing parameters i.e:
something like that, but i can't get it to work,Code:
// function call
can anyone help???
I hope I made my question clear enough??? if not let me know???