From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 235B43888C4A; Fri, 18 Mar 2022 15:42:31 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 235B43888C4A From: "cvs-commit at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug libstdc++/104242] [12 Regression] Class with constructor from std::any is not copyable Date: Fri, 18 Mar 2022 15:42:30 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: libstdc++ X-Bugzilla-Version: 12.0 X-Bugzilla-Keywords: rejects-valid X-Bugzilla-Severity: normal X-Bugzilla-Who: cvs-commit at gcc dot gnu.org X-Bugzilla-Status: NEW X-Bugzilla-Resolution: X-Bugzilla-Priority: P1 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: 12.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: Fri, 18 Mar 2022 15:42:31 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D104242 --- Comment #4 from CVS Commits --- The master branch has been updated by Jonathan Wakely : https://gcc.gnu.org/g:7a42b1fa1a090ead96cc0f94a8060a9650c810d5 commit r12-7708-g7a42b1fa1a090ead96cc0f94a8060a9650c810d5 Author: Jonathan Wakely Date: Fri Mar 18 13:10:01 2022 +0000 libstdc++: Simplify constraints for std::any construction [PR104242] Partially revert r12-4190-g6da36b7d0e43b6f9281c65c19a025d4888a25b2d because using __and_<..., is_copy_constructible> when T is incomplete results in an error about deriving from is_copy_constructible when that is incomplete. I don't know how to fix that, so this simply restores the previous constraint which worked in this case (even though I think it's technically undefined to use is_copy_constructible with incomplete T). This doesn't restore exactly what we had before, but uses the is_copy_constructible_v and __is_in_place_type_v variable templates instead of the ::value member. libstdc++-v3/ChangeLog: PR libstdc++/104242 * include/std/any (any(T&&)): Revert change to constraints. * testsuite/20_util/any/cons/104242.cc: New test.=