* decl.c (make_typename_type): s/parameters/arguments/.
[official-gcc.git] / gcc / testsuite / g++.dg / cpp0x / diag1.C
blob9bf7cfe5c8f921f47134621e7fc6768ef9779a49
1 // { dg-do compile { target c++11 } }
3 template <int U>
4 struct TypeA
6   typedef int type;
7 };
9 template <int N>
10 struct TypeB
12   template <int U> typename TypeA<U>::type fn();
15 struct TypeC
17   TypeB<10> b;
18   // This was being printed as:
19   // template<int N>
20   //   decltype (((TypeC*)this)->
21   //             TypeC::b.
22   //             template<int U> typename TypeA<U>::type TypeB::fn [with int U = U, int N = 10, typename TypeA<U>::type = TypeA<U>::type]())
23   //   TypeC::fn()
24   // we don't want to see the template header, return type, or parameter bindings
25   // for TypeB::fn.
26   template <int N> auto fn() -> decltype(b.fn<N>()); // { dg-bogus "typename|with" }
29 int main()
31   TypeC().fn<4>(1);             // { dg-error "no match" }