From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id C3545396DC3C; Thu, 2 Jun 2022 20:01:27 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org C3545396DC3C From: "cvs-commit at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/105803] [13 regression] ICE at gcc/cp/pt.cc:27737 after r13-860-gff91735a5b861d Date: Thu, 02 Jun 2022 20:01:27 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: c++ X-Bugzilla-Version: 13.0 X-Bugzilla-Keywords: ice-on-valid-code X-Bugzilla-Severity: normal X-Bugzilla-Who: cvs-commit at gcc dot gnu.org X-Bugzilla-Status: ASSIGNED X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: mpolacek at gcc dot gnu.org X-Bugzilla-Target-Milestone: 13.0 X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: 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: Thu, 02 Jun 2022 20:01:27 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D105803 --- Comment #11 from CVS Commits --- The trunk branch has been updated by Marek Polacek : https://gcc.gnu.org/g:7b98910406b5000a6429c188b0c6cc14e3140637 commit r13-968-g7b98910406b5000a6429c188b0c6cc14e3140637 Author: Marek Polacek Date: Wed Jun 1 18:21:36 2022 -0400 c++: ICE with template NEW_EXPR [PR105803] Here we ICE because value_dependent_expression_p gets a NEW_EXPR whose operand is a type, and we go to the default case which just calls v_d_e_p on each operand of the NEW_EXPR. Since one of them is a type, we crash on the new assert in t_d_e_p. t_d_e_p has code to handle {,VEC_}NEW_EXPR, which at this point was already performed, so I think we can handle these two codes specifically and skip the second operand, which is always going to be a type. PR c++/105803 gcc/cp/ChangeLog: * pt.cc (value_dependent_expression_p): Handle {,VEC_}NEW_EXPR in the switch. gcc/testsuite/ChangeLog: * g++.dg/template/new13.C: New test.=