https://gcc.gnu.org/bugzilla/show_bug.cgi?id=85866
Bug ID: 85866 Summary: [8 Regression] too few arguments to function when sfinae on calling pointer to member function Product: gcc Version: 8.1.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: gufideg at gmail dot com Target Milestone: --- This code fails under GCC 8: #include <utility> template<typename...> using void_t = void; template<typename U, typename V, void_t<decltype( (std::declval<U>().*std::declval<V>())() )>* = nullptr> void boom(){} struct Foo { void bar(){} }; int main() { boom<Foo, decltype(&Foo::bar)>(); } This particular code compiles on all other GCC versions since 4.7 It also compiles on all versions of clang since version 3.4 Live example: https://godbolt.org/g/viHnMn