From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 7B906385840C; Mon, 29 May 2023 22:45:53 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 7B906385840C DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1685400353; bh=XHRQ8IMihkgDI7AZKBajrzcp8vcNNw6tEWVvL4YS6Vw=; h=From:To:Subject:Date:From; b=xlCXcYB5hwziz5VKwHVdfDHdhaBnjNAuzb0JmkWy4l/5Q+8MXs3MEAat3R7XZ5VsX lvYMf751ZK/YEk6Jvr9TGOT99p/n+tLdKRfvvZc1jJkJ4muAF3emILflqg8Q5dipWb UnYhPtPBis/Ztbza0f+Slsv1PuvWMZca8Sg1VZ+k= From: "stevenxia990430 at gmail dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/110031] New: ICE: error reporting routines re-entered on non-type template argument Date: Mon, 29 May 2023 22:45:53 +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: stevenxia990430 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=3D110031 Bug ID: 110031 Summary: ICE: error reporting routines re-entered on non-type template argument Product: gcc Version: 12.1.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: stevenxia990430 at gmail dot com Target Milestone: --- The following program produces internal compiler error: error reporting routines re-entered. Checked on clang and it was rejected as invalid code. Tested on gcc trunk.=20 To quickly reproduce: https://gcc.godbolt.org/z/ex14EKeox ``` #include #include template constexpr void print_type() { std::cout << "Type: " << typeid(T).name(); } template >, int> =3D 0> struct A { A(T &&) { } }; template struct A { A(T &&) =3D delete; }; int main(void) { A a{5.3}; return 0; } ``` Note, if we comment out the A a{5.3}; line in main function, gcc-trunk actu= ally accept this code (compiles) however it is rejected by clang. Might be relat= ed to this: bug109390=