2 // { dg-do compile { target c++11 } }
7 template<class T, class Arg, class =
8 decltype(::new T(val<Arg>()))
10 auto test(int) -> char;
12 template<class, class>
13 auto test(...) -> char (&)[2];
16 explicit operator bool(); // (#13)
19 typedef decltype(test<bool, P>(0)) type; // OK
20 typedef decltype(test<float, P>(0)) type2; // Error (#17)