* decl.c (make_typename_type): s/parameters/arguments/.
[official-gcc.git] / gcc / testsuite / g++.dg / cpp0x / constexpr-targ2.C
blob285d6c9c1301447f3bdb7f12eda71e240fdf5867
1 // PR c++/65498
2 // { dg-do compile { target c++11 } }
4 template <typename, typename>
5 struct is_same
7   enum { value = false };
8   constexpr bool operator()() const noexcept { return value; }
9 };
11 template <typename T>
12 struct is_same<T, T>
14   enum { value = true };
15   constexpr bool operator()() const noexcept { return value; }
18 template <bool, typename = void>
19 struct enable_if { };
21 template <typename T>
22 struct enable_if<true, T> { typedef T type; };
24 struct A;
26 template <typename, typename = void>
27 struct F { };
29 template <typename X>
30 struct F<X, typename enable_if<is_same<X, A>{}()>::type> {
31     template <typename MakeDependent>
32     F(MakeDependent) {
33         auto ICE_HERE = __func__;
34         (void)ICE_HERE; // avoid -Wunused-variable
35     }
38 int main() {
39     F<A>{1};