D
Daniel.Wyatt
I need some help with this please. Here's the important part:
#include <vector>
#include <string>
................
template <class T>
bool ResourceManager<T>::isLoaded(const std::string Filename)
{
std::vector<T>::iterator it; //error: expected `;' before "it"
return false;
}
This won't compile. I'm using the newest MinGW, not that it matters. As
the comment says, the iterator declaration causes an error. I'm pretty
sure i've encountered this problem before but i can't remember how i
fixed it. If i replace the "T" template parameter in the iterator
declaration with a regular type, like an int, it compiles fine.
#include <vector>
#include <string>
................
template <class T>
bool ResourceManager<T>::isLoaded(const std::string Filename)
{
std::vector<T>::iterator it; //error: expected `;' before "it"
return false;
}
This won't compile. I'm using the newest MinGW, not that it matters. As
the comment says, the iterator declaration causes an error. I'm pretty
sure i've encountered this problem before but i can't remember how i
fixed it. If i replace the "T" template parameter in the iterator
declaration with a regular type, like an int, it compiles fine.