public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "amir.ahmed.ansari at outlook dot com" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/106351] New: ICE in fold expression involving templatized lambda Date: Tue, 19 Jul 2022 07:31:51 +0000 [thread overview] Message-ID: <bug-106351-4@http.gcc.gnu.org/bugzilla/> (raw) https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106351 Bug ID: 106351 Summary: ICE in fold expression involving templatized lambda Product: gcc Version: 12.1.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: amir.ahmed.ansari at outlook dot com Target Milestone: --- The following code: template <typename ...Args> struct C { void f() { ( [&, this]<typename Arg>() { }.operator()<Args>(), ... ); } }; int main() { C<int>{}.f(); return 0; } produces: <source>: In instantiation of 'void C<Args>::f() [with Args = {int}]': <source>:17:15: required from here <source>:9:30: internal compiler error: in lookup_template_class_1, at cp/pt.cc:10114 7 | [&, this]<typename Arg>() | ~~~~~~~~~~~~~~~~~~~~~~~~~ 8 | { | ~ 9 | }.operator()<Args>(), | ~~~~~~~~~~~~~~~~~^ 0x1ba65f9 internal_error(char const*, ...) ???:0 0x6fad32 fancy_abort(char const*, int, char const*) ???:0 0x87f6fd lookup_template_class(tree_node*, tree_node*, tree_node*, tree_node*, int, int) ???:0 0x875d31 tsubst(tree_node*, tree_node*, int, tree_node*) ???:0 0x881224 tsubst_pack_expansion(tree_node*, tree_node*, int, tree_node*) ???:0 0x878889 instantiate_decl(tree_node*, bool, bool) ???:0 0x8936ab instantiate_pending_templates(int) ???:0 0x79c46d c_parse_final_cleanups() ???: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://gcc.gnu.org/bugs/> for instructions. ASM generation compiler returned: 1
next reply other threads:[~2022-07-19 7:31 UTC|newest] Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top 2022-07-19 7:31 amir.ahmed.ansari at outlook dot com [this message] 2022-07-19 10:19 ` [Bug c++/106351] " marxin at gcc dot gnu.org 2022-08-09 7:09 ` pinskia 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-106351-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).