|
-
November 26th, 2009, 11:25 PM
#1
iterator for a list of template objects
Hi,
I have a compilation probleme when I create my iterator for a stl list of template object. This is the situation
template <typename T>
class A
{
...
};
template <typename T >
class B
{
....
private :
std::list<A<T> >m_MyList;
std::list<A<T> >::iterator m_MyIter;
};
Compiler give me this warning :
warning C4346: 'std::list<A<T> >::iterator' : dependent name is not a type
I have also this error when I use m_MyIter
error C2146: syntax error : missing ';' before identifier 'm_MyIter'
What is the best way to correct ths problem Thank you
}
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|