This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
Internal compiler error 61
- To: egcs-bugs at egcs dot cygnus dot com
- Subject: Internal compiler error 61
- From: Nick Rasmussen <nick at jive dot org>
- Date: Mon, 05 Jul 1999 07:54:17 -0500
The following code causes an internal compiler error (61) with the current head of
the gcc-2.95 branch.
With the template removed from iterator, it gives the warning:
foo.C:16: warning: lookup of `iterator' finds `struct iterator'
foo.C:16: warning: instead of `HashTable<T>::iterator' from dependent base class
foo.C:16: warning: (use `typename HashTable::iterator' if that's what you meant)
-nick
template <class T>
struct iterator {
};
template <class T>
class map {
public:
typedef int iterator;
static void erase(iterator __position);
};
template<class T>
class HashTable {
public:
typedef map<T> hash;
typedef hash::iterator iterator;
void erase(iterator i) { hash::erase(i); return; }
};