re PR c++/65619 (friend declaration with template template parameter not recognized)

2019-04-04  Paolo Carlini  <paolo.carlini@oracle.com>

	PR c++/65619
	* g++.dg/template/friend67.C: New.

From-SVN: r270146
This commit is contained in:
Paolo Carlini 2019-04-04 15:49:30 +00:00 committed by Paolo Carlini
parent a7f70a0925
commit 3a36c1806a
2 changed files with 31 additions and 0 deletions

View File

@ -1,3 +1,8 @@
2019-04-04 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/65619
* g++.dg/template/friend67.C: New.
2019-04-04 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/61327

View File

@ -0,0 +1,26 @@
// PR c++/65619
template <class>
class foo
{
int i;
template <template <class> class T>
friend foo<T<int> > func();
};
template <template <class> class T>
foo<T<int> > func()
{
foo<T<int> > f;
f.i = 3;
return f;
}
template <class>
struct test {};
int main()
{
func<test>();
}