Hi chipper, cpjust,
cpjust, yeah... I can see how to implement it.. but it will require a declaration in the client code that defines the type of my template class, a little messy. Moreover, it makes it necessary to create another instance of my class for each different type of vector...
chipper,
thank you for the quick response.
I hope my question is clear,
I don't need to create a new class,
I want to define the type of the vector that will be created at run time.
for example:
template <class T>
MyClass::WorkItOut<T>(vector<T> input, int size);
{
string datatype =...
Hello all,
I hope this thread matches in here.
I'm working in Visual c++ 6.0.
I am trying to create a vector that will be used as a buffer for an algorithm. The problem is that I want the algorithm to work on a "template" type vector.
Therefore, my buffer vector must be created at run time...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.