https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107033
Bug ID: 107033 Summary: [13 Regression] [modules] ICE converting to span Product: gcc Version: 13.0 Status: UNCONFIRMED Keywords: rejects-valid Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: johelegp at gmail dot com CC: johelegp at gmail dot com Target Milestone: --- See GCC trunk: https://godbolt.org/z/KoP5qo1Ks. See GCC 12: https://godbolt.org/z/EfGjdcYaW. ```sh CXX=/home/johel/root/gcc/bin/g++ echo "./std.hpp std.gcm mod mod.gcm" > mm.txt echo "#include <array> #include <span>" > std.hpp echo "export module mod; import \"std.hpp\"; constexpr std::array<int, 1> a = {}; export constexpr std::span s = a;" > mod.cpp $CXX -std=c++23 -fmodules-ts -fmodule-mapper=mm.txt -x c++-header -c std.hpp $CXX -std=c++23 -fmodules-ts -fmodule-mapper=mm.txt -c mod.cpp ``` Output: ``` mod.cpp:1:8: internal compiler error: Segmentation fault 1 | export module mod; | ^~~~~~ 0x22c23ec internal_error(char const*, ...) ???:0 0xba7787 walk_specializations(bool, void (*)(bool, spec_entry*, void*), void*) ???:0 0xafa362 depset::hash::add_specializations(bool) ???:0 0xb0ab3c module_state::write_begin(elf_out*, cpp_reader*, module_state_config&, unsigned int&) ???:0 0xb0c044 finish_module_processing(cpp_reader*) ???:0 0xa95334 c_parse_final_cleanups() ???:0 0xccde92 c_common_parse_file() ???:0 Please submit a full bug report, with preprocessed source (by using -freport-bug). Please include the complete backtrace with any bug report. See <https://bugs.archlinux.org/> for instructions. ```