https://gcc.gnu.org/bugzilla/show_bug.cgi?id=123075
--- Comment #3 from Nathaniel Shead <nshead at gcc dot gnu.org> ---
Reduced:
export module M;
template <typename T> concept r = []{ return true; }();
template <typename T> inline void foo() { r<T>; }
template void foo<int>();
The instantiation of the concept for some reason is attaching the lambda to the
function decl, which we're not prepared to handle. We previously just treated
this as an unmergeable entity, which I don't think is correct (we should be
able to merge this, but it needs to be keyed to the concept not just wherever
it's instantiated).