What I want to do is to store the function address of a templated function. An idea of what I want to do:
Code:
class SMC
{
public:
template <class type> printy(int a)
{
for (type i=0; i<10; i++)
cout << a;
}
Special_MethodCall()
{
void (SMC::*boo)(int)=&SMC::printy<int>;
}
};
You see, what I want to do is to make a encoding function that can encode various types of array data. Therefore --> templates. I want to put these all in a class and get function pointers to specific templates of them, like ex: printy<float>.
However, when I try to compile this under MS C++, it gives me a fatal compiler error. Not good, how would you do this?