This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/51789] GCC does not consider SFINAE in template parameter list of template parameter pack
- From: "redi at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Fri, 18 Aug 2017 15:47:38 +0000
- Subject: [Bug c++/51789] GCC does not consider SFINAE in template parameter list of template parameter pack
- Auto-submitted: auto-generated
- References: <bug-51789-4@http.gcc.gnu.org/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=51789
Jonathan Wakely <redi at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Keywords| |accepts-invalid
Status|WAITING |NEW
--- Comment #2 from Jonathan Wakely <redi at gcc dot gnu.org> ---
Yes, it is not a complete testcase. It should have #include <type_traits>, or
here's a complete version:
namespace std {
template<typename T, typename U> struct is_same { static const bool value =
false; };
template<typename T> struct is_same<T, T> { static const bool value = true; };
template<bool, typename T = void> struct enable_if { };
template<typename T> struct enable_if<true, T> { using type = T; };
}
struct A {
template<
typename ...T,
template<typename std::enable_if<
std::is_same<T, int>::value, int
>::type ...
> class...
>
A(T...);
};
A a = {1, 2.0, 3};