c++/3028: 3.0 Compiler complains about template that used to work under 2.95

Gabriel Dos Reis Gabriel.Dos-Reis@cmla.ens-cachan.fr
Fri Jun 1 18:20:00 GMT 2001


| > template<class ALLOC> class IListBase 
| > {
| >  protected:
| >   struct IListNode 
| >   {
| >     IListNode *next;
| >     int datum;
| >   };
| >   
| >   class IListNode *head;
| >   class IListNode *tail;
| >   
| >   int find(int datum);
| > };
| > 
| > template<class ALLOC> int IListBase<ALLOC>::find(int d)
| > {
| >   IListNode<ALLOC> *node;
      ^^^^^^^^^

There is no template-name 'IListNode' defined at this point.  Lookup
finds only a NON-template-name (member) name.

-- Gaby



More information about the Gcc-bugs mailing list