2003-12-26 Guilhem Lavaux <guilhem@kaffe.org>
[official-gcc.git] / gcc / testsuite / g++.old-deja / g++.pt / memtemp20.C
blob0295c9786f3048e88063b11e19b42960726ba9f7
1 // { dg-do link  }
2 // GROUPS passed templates membertemplates
3 extern "C" int printf(const char*, ...);
5 struct S
7   template <class T, class U>
8   void foo(T t, U u);
10   template <class U>
11   void foo(char*, U);
13   void foo(int i);
16 template <class T, class U>
17 void S::foo(T t, U u)
19   printf ("T,U version\n");
23 template <class U>
24 void S::foo(char*, U u)
26   printf ("char*,U version\n");
30 void S::foo(int i)
32   printf ("int version\n");
36 int main()
38   S s;
39   s.foo(3);
40   s.foo(3, 3);
41   s.foo("abc", s);