S
Sensei
Hi! I am trying to create a function template that converts a type to a
string, unsuccessfully! What did I think of? Overloading a function,
with a vector class, just to try if it works:
template<class T> string toString(T src) {...};
template<class T> string toString(vector<T> src) {...};
What happens is that the first one is called, ignoring the other when
passing a vector of, for example, double.
What am I missing?
Thanks for your help!
string, unsuccessfully! What did I think of? Overloading a function,
with a vector class, just to try if it works:
template<class T> string toString(T src) {...};
template<class T> string toString(vector<T> src) {...};
What happens is that the first one is called, ignoring the other when
passing a vector of, for example, double.
What am I missing?
Thanks for your help!