how would i define a function ptr which points to a function which gives back a boolean but takes two unknown (but equal) types as arguments?
Should be something like this, but my IDE marks this as wrong:
template<class arg>
bool (ptr*)(arg,arg);
I also want to combine this with a function which takes such a function-ptr to compare two arguments it gets.
like:
template<class arg>
void function(arg one,arg two,ptr comparefunction)
Is something like this even possible?
You can’t have template typedefs, which seems to be what you’re asking about initially. For the function which takes a function pointer you can do:
instead.
Your initial syntax is also wrong: