[Bug c++/107875] Deduction for class template specialization types seems to be broken with init-declarator-list with lambda as default template argument

ddvamp007 at gmail dot com gcc-bugzilla@gcc.gnu.org
Thu Feb 19 05:55:21 GMT 2026


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107875

Artyom Kolpakov <ddvamp007 at gmail dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |ddvamp007 at gmail dot com

--- Comment #2 from Artyom Kolpakov <ddvamp007 at gmail dot com> ---
A slightly different example (https://godbolt.org/z/fnr43eaav)

#include <type_traits>

template <auto = []{}> struct S {};
template <typename = S<>> struct T {};
T x, y;

static_assert(std::is_same_v<decltype(x), decltype(y)>);


More information about the Gcc-bugs mailing list