public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "jakub at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/100234] New: [11/12 Regression] Coroutines ICE Date: Fri, 23 Apr 2021 15:39:28 +0000 [thread overview] Message-ID: <bug-100234-4@http.gcc.gnu.org/bugzilla/> (raw) https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100234 Bug ID: 100234 Summary: [11/12 Regression] Coroutines ICE Product: gcc Version: 11.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: jakub at gcc dot gnu.org Target Milestone: --- Starting with r11-2183-g0f66b8486cea8668020e4bd48f261b760cb579be the following testcase ICEs with -std=c++20 -fcoroutines: rh1952671.C: In member function ‘K L::bar()’: rh1952671.C:44:41: internal compiler error: tree check: expected record_type or union_type or qual_union_type, have array_type in build_special_member_call, at cp/call.c:9758 44 | K bar () { co_await foo (C(), {C()}); } | ^ 0x1a5f2ac tree_check_failed(tree_node const*, char const*, int, char const*, ...) ../../gcc/tree.c:9687 0x958126 tree_check3(tree_node*, char const*, int, char const*, tree_code, tree_code, tree_code) ../../gcc/tree.h:3343 0x94b8b3 build_special_member_call(tree_node*, tree_node*, vec<tree_node*, va_gc, vl_embed>**, tree_node*, int, int) ../../gcc/cp/call.c:9758 0x9d8490 flatten_await_stmt ../../gcc/cp/coroutines.cc:2859 namespace std { template <class> class initializer_list { int *a; decltype(sizeof 0) b; }; } struct C { C(); }; struct D { D(std::initializer_list<C>); }; namespace std { template <typename e, typename> struct coroutine_traits : e {}; template <typename = void> struct coroutine_handle { operator coroutine_handle<>(); }; } struct F { void await_ready(); void await_suspend(std::coroutine_handle<>); void await_resume(); }; struct M { void await_ready() noexcept; template <typename h> void await_suspend(h) noexcept; void await_resume() noexcept; }; struct I { F initial_suspend(); auto final_suspend() noexcept { return M{}; } }; struct K { struct J : public I { void unhandled_exception(); // K get_return_object() { return K{}; } }; using promise_type = J; }; struct Q { Q(int); void await_ready(); void await_resume(); void await_suspend(std::coroutine_handle<>); }; Q foo (C, D); struct L { K bar () { co_await foo (C(), {C()}); } }; while before that commit it has been rejected with rh1952671.C: In member function ‘K L::bar()’: rh1952671.C:44:5: error: no member named ‘get_return_object’ in ‘K::promise_type’ {aka ‘K::J’} 44 | K bar () { co_await foo (C(), {C()}); } | ^~~
next reply other threads:[~2021-04-23 15:39 UTC|newest] Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top 2021-04-23 15:39 jakub at gcc dot gnu.org [this message] 2021-04-23 15:39 ` [Bug c++/100234] " jakub at gcc dot gnu.org 2021-04-23 15:47 ` jakub at gcc dot gnu.org
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=bug-100234-4@http.gcc.gnu.org/bugzilla/ \ --to=gcc-bugzilla@gcc.gnu.org \ --cc=gcc-bugs@gcc.gnu.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).