From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 453DC3858439; Thu, 23 Feb 2023 17:29:04 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 453DC3858439 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1677173344; bh=FDWiyRTE2Pll0JNow5c7IUj4mVggnNW4satUndx72W0=; h=From:To:Subject:Date:In-Reply-To:References:From; b=iKkTDxGapg+MhhfAGsxhhheXWJCYv+8zRFU5YXY5DIGl526Binb92X2JPIQOAgM4N gldpMI8taMVq3racXe7veBapsR0+k5ZEf0TE98wml8NPDvWm+bbqt7F0KkFgOAyZ2v /UaMPU6RB7yCeTNhba3knyzTfZMzAFj6xV4dpMWg= From: "arthur.j.odwyer at gmail dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug libstdc++/108846] std::copy, std::copy_n and std::copy_backward on potentially overlapping subobjects Date: Thu, 23 Feb 2023 17:29:03 +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: 13.0 X-Bugzilla-Keywords: ABI X-Bugzilla-Severity: normal X-Bugzilla-Who: arthur.j.odwyer at gmail dot com X-Bugzilla-Status: NEW 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: 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=3D108846 --- Comment #11 from Arthur O'Dwyer --- (In reply to Jonathan Wakely from comment #10) > std::move(x,y,z) and std::copy(z,y,z) use the same underlying > implementation, so it does have the same issue, but will be fixed by the > same change. Right; also std::rotate, std::set_union, etc., I'd expect would all be fixe= d by the same change to std::copy. You might want to peek at std::swap_ranges, though. Microsoft's STL has tro= uble there; I don't *think* libstdc++ does, but you might as well check me.=