https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115062
Nathaniel Shead <nshead at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Ever confirmed|0 |1 Keywords| |ice-on-valid-code Status|UNCONFIRMED |NEW Last reconfirmed| |2024-08-08 CC| |nshead at gcc dot gnu.org --- Comment #1 from Nathaniel Shead <nshead at gcc dot gnu.org> --- Confirmed. Reduced: // pr115062_a.H template <typename T> class S; typedef S<char> X; // pr115062_b.H template <typename> struct S { int a; long b; union {}; ~S(); void foo(); }; extern template void S<char>::foo(); S<char> operator+(S<char>, const char *); // pr115062_c.C export module hello; import "pr115062_a.hpp"; import "pr115062_b.hpp"; X x = X() + ""; g++-15 -fmodules-ts -S pr115062_* pr115062_c.C: In function ‘void __static_initialization_and_destruction_0()’: pr115062_c.C:4:13: internal compiler error: in simplify_aggr_init_expr, at cp/semantics.cc:4958 4 | X x = X() + ""; | ^~