OSDN Git Service

/cp
[pf3gnuchains/gcc-fork.git] / gcc / testsuite / g++.dg / template / canon-type-9.C
1 // Contributed by Dodji Seketeli <dodji@redhat.com>
2 // { dg-options "-std=c++0x" }
3 // { dg-do compile }
4
5 struct F { F(int) {}};
6
7 template<class T, T* u>
8 struct S
9 {
10   decltype(u) foo(T);
11 };
12
13 template<class T, T *u>
14 decltype(u) S<T, u>::foo(T)
15 {
16   T t;
17   return t;
18 }