From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 367BA3858413; Tue, 2 Apr 2024 18:11:24 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 367BA3858413 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1712081485; bh=qYeb1va4mpNIgrP3nLixEcEkEx4qWFtFYXIc43iVQyY=; h=From:To:Subject:Date:In-Reply-To:References:From; b=BYsR+t3u0+Y/622QwiMv3CPyLA2CLsphrk5DZJJ1+7nqngT9R61cVHbuuxRhSHz0x bUtBPrL6BqC9L+Neib1U6Y4AC3UxFQzWHC0tpJdWqha5DdfgO5AxnF7tBs6/oJh4ue 0u2G3QhIJSLK2o4WKAU/K13CqCoRYrxAs5hg8omE= From: "cvs-commit at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/114562] [11/12/13/14 Regression] ICE when trying to bind rvalue reference to lvalue with comma operator and forwarding reference to pointer since r10-7410 Date: Tue, 02 Apr 2024 18:11:23 +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: 14.0 X-Bugzilla-Keywords: ice-on-invalid-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: jason at gcc dot gnu.org X-Bugzilla-Target-Milestone: 11.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=3D114562 --- Comment #2 from GCC Commits --- The trunk branch has been updated by Jason Merrill : https://gcc.gnu.org/g:5d7e9a35024f065b25f61747859c7cb7a770c92b commit r14-9757-g5d7e9a35024f065b25f61747859c7cb7a770c92b Author: Jason Merrill Date: Tue Apr 2 10:52:28 2024 -0400 c++: binding reference to comma expr [PR114561] We represent a reference binding where the referent type is more qualif= ied by a ck_ref_bind around a ck_qual. We performed the ck_qual and then t= ried to undo it with STRIP_NOPS, but that doesn't work if the conversion is buried in COMPOUND_EXPR. So instead let's avoid performing that fake conversion in the first place. PR c++/114561 PR c++/114562 gcc/cp/ChangeLog: * call.cc (convert_like_internal): Avoid adding qualification conversion in direct reference binding. gcc/testsuite/ChangeLog: * g++.dg/conversion/ref10.C: New test. * g++.dg/conversion/ref11.C: New test.=