From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 143483858C5F; Wed, 15 Mar 2023 18:28:27 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 143483858C5F DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1678904907; bh=/8DE3/JsLxfKGNTmbYU6UjzjIO0BysrEECyivuW+nOY=; h=From:To:Subject:Date:In-Reply-To:References:From; b=xl80BewwoLhwZIcdWQ1efR4H3mJW/r3/p3wLYKn4SCu/3f+xdwpahXBsNZ4BtdKrc rseUvMdwV4MiK87XnjW087ZtZUFSZlhbg9rXP0SF0D4GPBEfgxhHqxrqAvuwl8/l2Y WD7YQp0dWWE+vR4o4zHAmnACLFsuJgYa0i1e+VHY= From: "cvs-commit at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/107280] [10/11/12/13 Regression] ICE: tree check: expected constructor, have view_convert_expr in cxx_eval_store_expression, at cp/constexpr.cc:5928 Date: Wed, 15 Mar 2023 18:28:26 +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: P2 X-Bugzilla-Assigned-To: mpolacek at gcc dot gnu.org X-Bugzilla-Target-Milestone: 10.5 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 List-Id: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D107280 --- Comment #5 from CVS Commits --- The trunk branch has been updated by Marek Polacek : https://gcc.gnu.org/g:be20dcc359bcc4677c5b9ce011d3cd7b4ce94a64 commit r13-6697-gbe20dcc359bcc4677c5b9ce011d3cd7b4ce94a64 Author: Marek Polacek Date: Fri Mar 10 10:14:20 2023 -0500 c++: ICE with constexpr lambda [PR107280] We crash here since r10-3661, the store_init_value hunk in particular. Before, we called cp_fully_fold_init, so e.g. {.str=3DVIEW_CONVERT_EXPR("")} was folded into {.str=3D""} but now we don't fold and keep the VCE around, and it causes trouble in cxx_eval_store_expression: in the !refs->is_empty () loop we descend on .str's initializer but since it's wrapped in a VCE, we skip the STRING_= CST check and then crash on the CONSTRUCTOR_NO_CLEARING. PR c++/107280 gcc/cp/ChangeLog: * constexpr.cc (cxx_eval_store_expression): Strip location wrappers. gcc/testsuite/ChangeLog: * g++.dg/cpp1z/constexpr-lambda28.C: New test.=