https://gcc.gnu.org/bugzilla/show_bug.cgi?id=120877
Bug ID: 120877 Summary: internal compiler error: Segmentation fault since 10.1 with std=c++20 Product: gcc Version: 16.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: mario.rodriguezb1 at um dot es Target Milestone: --- Program: ``` #include <variant> #include <iostream> using var = any_name<int, bool, char>; var v = 5; get<std::decay_t<decltype(v)>::index_of_type<int>>(v) =5; ``` Stack dump: ``` <source>:5:53: internal compiler error: Segmentation fault 5 | get<std::decay_t<decltype(v)>::index_of_type<int>>(v) =5; | ^ 0x2844425 diagnostic_context::diagnostic_impl(rich_location*, diagnostic_metadata const*, diagnostic_option_id, char const*, __va_list_tag (*) [1], diagnostic_t) ???:0 0x2866fc6 internal_error(char const*, ...) ???:0 0xd988cb finish_call_expr(tree_node*, vec<tree_node*, va_gc, vl_embed>**, bool, bool, int) ???:0 0xd166e3 c_parse_file() ???:0 0xe7e469 c_common_parse_file() ???:0 ``` To quickly reproduce: https://godbolt.org/z/ncMbrfbdP