From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id BD9F93858439; Tue, 19 Jul 2022 07:31:51 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org BD9F93858439 From: "amir.ahmed.ansari at outlook dot com" 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 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: c++ X-Bugzilla-Version: 12.1.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: amir.ahmed.ansari at outlook dot com X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter target_milestone Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: gcc-bugs@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-bugs mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 19 Jul 2022 07:31:51 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D106351 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 struct C { void f() { ( [&, this]() { }.operator()(), ... ); } }; int main() { C{}.f(); return 0; } produces: : In instantiation of 'void C::f() [with Args =3D {int}]': :17:15: required from here :9:30: internal compiler error: in lookup_template_class_1, at cp/pt.cc:10114 7 | [&, this]() | ~~~~~~~~~~~~~~~~~~~~~~~~~ 8 | { | ~=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20 9 | }.operator()(), | ~~~~~~~~~~~~~~~~~^ 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_nod= e*, 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 for instructions. ASM generation compiler returned: 1=