https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102217
Arsen Arsenović <arsen at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |arsen at gcc dot gnu.org --- Comment #8 from Arsen Arsenović <arsen at gcc dot gnu.org> --- hm, I see an ICE in 14.1 still: ~$ g++ -std=c++23 max-ice.cc max-ice.cc: In function ‘Co::Task<Foo> FooC(bool)’: max-ice.cc:171:1: internal compiler error: in flatten_await_stmt, at cp/coroutines.cc:2875 171 | } | ^ 0x5578f31eb661 flatten_await_stmt /usr/src/debug/sys-devel/gcc-14.1.1_p20240713/gcc-14-20240713/gcc/cp/coroutines.cc:2875 0x5578f31eb804 flatten_await_stmt /usr/src/debug/sys-devel/gcc-14.1.1_p20240713/gcc-14-20240713/gcc/cp/coroutines.cc:2904 0x5578f31eb804 flatten_await_stmt /usr/src/debug/sys-devel/gcc-14.1.1_p20240713/gcc-14-20240713/gcc/cp/coroutines.cc:2904 0x5578f31f4281 maybe_promote_temps /usr/src/debug/sys-devel/gcc-14.1.1_p20240713/gcc-14-20240713/gcc/cp/coroutines.cc:3087 0x5578f31f4281 await_statement_walker /usr/src/debug/sys-devel/gcc-14.1.1_p20240713/gcc-14-20240713/gcc/cp/coroutines.cc:3726 0x5578f3d042cb walk_tree_1(tree_node**, tree_node* (*)(tree_node**, int*, void*), void*, hash_set<tree_node*, false, default_hash_traits<tree_node*> >*, tree_node* (*)(tree_node**, int*, tree_node* (*)(tree_node**, int*, void*), void*, hash_set<tree_node*, false, default_hash_traits<tree_node*> >*)) /usr/src/debug/sys-devel/gcc-14.1.1_p20240713/gcc-14-20240713/gcc/tree.cc:11468 0x5578f31f2df8 await_statement_walker /usr/src/debug/sys-devel/gcc-14.1.1_p20240713/gcc-14-20240713/gcc/cp/coroutines.cc:3397 0x5578f3d042cb walk_tree_1(tree_node**, tree_node* (*)(tree_node**, int*, void*), void*, hash_set<tree_node*, false, default_hash_traits<tree_node*> >*, tree_node* (*)(tree_node**, int*, tree_node* (*)(tree_node**, int*, void*), void*, hash_set<tree_node*, false, default_hash_traits<tree_node*> >*)) /usr/src/debug/sys-devel/gcc-14.1.1_p20240713/gcc-14-20240713/gcc/tree.cc:11468 0x5578f31f3f59 await_statement_walker /usr/src/debug/sys-devel/gcc-14.1.1_p20240713/gcc-14-20240713/gcc/cp/coroutines.cc:3674 0x5578f3d042cb walk_tree_1(tree_node**, tree_node* (*)(tree_node**, int*, void*), void*, hash_set<tree_node*, false, default_hash_traits<tree_node*> >*, tree_node* (*)(tree_node**, int*, tree_node* (*)(tree_node**, int*, void*), void*, hash_set<tree_node*, false, default_hash_traits<tree_node*> >*)) /usr/src/debug/sys-devel/gcc-14.1.1_p20240713/gcc-14-20240713/gcc/tree.cc:11468 0x5578f31f2d8c await_statement_walker /usr/src/debug/sys-devel/gcc-14.1.1_p20240713/gcc-14-20240713/gcc/cp/coroutines.cc:3386 0x5578f3d042cb walk_tree_1(tree_node**, tree_node* (*)(tree_node**, int*, void*), void*, hash_set<tree_node*, false, default_hash_traits<tree_node*> >*, tree_node* (*)(tree_node**, int*, tree_node* (*)(tree_node**, int*, void*), void*, hash_set<tree_node*, false, default_hash_traits<tree_node*> >*)) /usr/src/debug/sys-devel/gcc-14.1.1_p20240713/gcc-14-20240713/gcc/tree.cc:11468 0x5578f31f2df8 await_statement_walker /usr/src/debug/sys-devel/gcc-14.1.1_p20240713/gcc-14-20240713/gcc/cp/coroutines.cc:3397 0x5578f3d042cb walk_tree_1(tree_node**, tree_node* (*)(tree_node**, int*, void*), void*, hash_set<tree_node*, false, default_hash_traits<tree_node*> >*, tree_node* (*)(tree_node**, int*, tree_node* (*)(tree_node**, int*, void*), void*, hash_set<tree_node*, false, default_hash_traits<tree_node*> >*)) /usr/src/debug/sys-devel/gcc-14.1.1_p20240713/gcc-14-20240713/gcc/tree.cc:11468 0x5578f3d043d7 walk_tree_1(tree_node**, tree_node* (*)(tree_node**, int*, void*), void*, hash_set<tree_node*, false, default_hash_traits<tree_node*> >*, tree_node* (*)(tree_node**, int*, tree_node* (*)(tree_node**, int*, void*), void*, hash_set<tree_node*, false, default_hash_traits<tree_node*> >*)) /usr/src/debug/sys-devel/gcc-14.1.1_p20240713/gcc-14-20240713/gcc/tree.cc:11702 0x5578f31f2df8 await_statement_walker /usr/src/debug/sys-devel/gcc-14.1.1_p20240713/gcc-14-20240713/gcc/cp/coroutines.cc:3397 0x5578f3d042cb walk_tree_1(tree_node**, tree_node* (*)(tree_node**, int*, void*), void*, hash_set<tree_node*, false, default_hash_traits<tree_node*> >*, tree_node* (*)(tree_node**, int*, tree_node* (*)(tree_node**, int*, void*), void*, hash_set<tree_node*, false, default_hash_traits<tree_node*> >*)) /usr/src/debug/sys-devel/gcc-14.1.1_p20240713/gcc-14-20240713/gcc/tree.cc:11468 0x5578f31f2d8c await_statement_walker /usr/src/debug/sys-devel/gcc-14.1.1_p20240713/gcc-14-20240713/gcc/cp/coroutines.cc:3386 0x5578f3d042cb walk_tree_1(tree_node**, tree_node* (*)(tree_node**, int*, void*), void*, hash_set<tree_node*, false, default_hash_traits<tree_node*> >*, tree_node* (*)(tree_node**, int*, tree_node* (*)(tree_node**, int*, void*), void*, hash_set<tree_node*, false, default_hash_traits<tree_node*> >*)) /usr/src/debug/sys-devel/gcc-14.1.1_p20240713/gcc-14-20240713/gcc/tree.cc:11468 0x5578f32269b1 morph_fn_to_coro(tree_node*, tree_node**, tree_node**) /usr/src/debug/sys-devel/gcc-14.1.1_p20240713/gcc-14-20240713/gcc/cp/coroutines.cc:4477 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.gentoo.org/> for instructions. ~ 1 $ (I have checking enabled on the system compiler) that line is: gcc_checking_assert (TREE_CODE (inner) != COND_EXPR); ... so, not too surprising ternaries crash it :-)