From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 086AC385842E; Mon, 29 Jan 2024 07:57:17 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 086AC385842E DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1706515037; bh=xAuibXsg51+J5ZNhe8IJPPWlaTSvLLLtsNOJzd1XAuo=; h=From:To:Subject:Date:From; b=xjAZC3HOH7dXkavzr5wYfL+s8PfIyWNb1BxMATwxx4ppTfIFDQ87kf3mzg5JEkRBB P+0YbPtJc2zw6SNq3Om8j2H52IoJUj6EFdxWpjynAMRMq0C0bz+kEyX8az76c/ValE /w7L18tBddF0FBYMGQPeN/Ei0O/g6vfqcrNTh4sw= From: "schaumb at gmail dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/113649] New: ICE: nested template class template argument deduction Date: Mon, 29 Jan 2024 07:57:16 +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: 14.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: schaumb at gmail 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 List-Id: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D113649 Bug ID: 113649 Summary: ICE: nested template class template argument deduction Product: gcc Version: 14.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: schaumb at gmail dot com Target Milestone: --- The following code does not compile, see here https://godbolt.org/z/vz5KMzh= sh: template struct params { template struct return_type { constexpr return_type(Return (*p1)(Ts...)){} }; template return_type(Return (*)(Ts...)) ->=20 return_type; template struct addr {}; }; void x(double); template struct params::addr<&x>; It runs to internal compiler error: :19:40: internal compiler error: in build_function_type, at tree.cc:7488 19 | template struct params::addr<&x>; | ^ 0x2647edc internal_error(char const*, ...) ???:0 0xa51cb7 fancy_abort(char const*, int, char const*) ???:0 0xc72375 do_auto_deduction(tree_node*, tree_node*, tree_node*, int, auto_deduction_context, tree_node*, int, tree_node*) ???:0 0xc76223 coerce_template_parms(tree_node*, tree_node*, tree_node*, int, boo= l) ???:0 0xc93089 lookup_template_class(tree_node*, tree_node*, tree_node*, tree_nod= e*, int, int) ???:0 0xccf8ff finish_template_type(tree_node*, tree_node*, int) ???:0 0xc53d2a c_parse_file() ???:0 0xda79a9 c_common_parse_file() ???: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. Compiler returned: 1=