re PR c++/7983 (ICE for friend declaration using typedef in class template)

PR c++/7983
	* g++.dg/parse/typedef4.C: New test.

From-SVN: r70051
This commit is contained in:
Kriang Lerdsuwanakij 2003-08-01 15:41:27 +00:00 committed by Kriang Lerdsuwanakij
parent b00badcd91
commit d6f7c70410
2 changed files with 17 additions and 0 deletions

View File

@ -1,3 +1,8 @@
2003-08-01 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
PR c++/7983
* g++.dg/parse/typedef4.C: New test.
2003-08-01 Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net>
PR c++/8442, c++/8806

View File

@ -0,0 +1,12 @@
// { dg-do compile }
// Origin: Matt Austern <austern@apple.com>
// PR c++/7983: ICE typedef to typename as friend.
template<class T> class smart_ptr2 {
T* real_ptr;
public:
typedef typename T::subT td;
friend class td; // { dg-error "typename|not name a class" }
};