https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86932
--- Comment #1 from zennehoy <zennehoy at gmail dot com> --- Sorry, I included the problematic void non-type template parameter pack. The type of std::enable_if_t should be specified as something other than void, e.g., int: #include <type_traits> template<class U, typename std::enable_if_t<std::is_const_v<U>, int>...> void f() {} int main() { f<int>(); }