// PR c++/116714 // PR c++/107390 // { dg-do compile { target c++20 } } template inline constexpr bool is_same_v = __is_same(T, U); template struct is_same { static constexpr bool value = false; }; template struct is_same { static constexpr bool value = true; }; template void f() { using type = decltype([]{}); static_assert(is_same_v); static_assert(is_same::value); }; template void g() { using ty1 = decltype([]{}); using ty2 = ty1; static_assert(is_same_v); static_assert(is_same::value); }; template void h() { using ty1 = decltype([]{}); using ty2 = decltype([]{}); static_assert(!is_same_v); static_assert(!is_same::value); }; template void f(); template void g(); template void h();