https://gcc.gnu.org/bugzilla/show_bug.cgi?id=112273
Bug ID: 112273 Summary: gcc crashs when checking satisfaction a constraint of lambda function Product: gcc Version: 14.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: rungecc at gmail dot com Target Milestone: --- Created attachment 56468 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=56468&action=edit ICE output ```c++ template <class... Ts> struct Tp {}; template <class... T> struct make_delayed { static constexpr inline bool value = true; }; template <class... T> concept K = make_delayed<T...>::value; [[maybe_unused]] constexpr auto ice(auto... arg) { using Tp_t = Tp<decltype(arg)...>; return []() requires K<Tp_t> { return 1; }; }; int main() { constexpr auto l = ice(1, 2); static_assert(l() == 1); return 0; } ``` See also [online compiler](https://godbolt.org/z/r8K4bK199). Gcc (checked version 14.0, 13.2, 12.3) with flag `-std=c++2b` crashed on the above code snippets. Output, see the attachment. **NOTE**: Seems we need 1) a dependent constraint attached to some function and 2) such constraint refers to a type contains a (dependent) pack expansion in it's definition to trigger this ICE.