From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 1C2113858D35; Fri, 14 Jan 2022 16:20:16 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 1C2113858D35 From: "ensadc at mailnesia dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug libstdc++/104032] New: Cannot move-assign a spanstream Date: Fri, 14 Jan 2022 16:20:15 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new 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: ensadc at mailnesia dot com X-Bugzilla-Status: UNCONFIRMED 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: bug_id short_desc product version bug_status keywords bug_severity priority component assigned_to reporter target_milestone Message-ID: 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, 14 Jan 2022 16:20:16 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D104032 Bug ID: 104032 Summary: Cannot move-assign a spanstream Product: gcc Version: 12.0 Status: UNCONFIRMED Keywords: rejects-valid Severity: normal Priority: P3 Component: libstdc++ Assignee: unassigned at gcc dot gnu.org Reporter: ensadc at mailnesia dot com Target Milestone: --- https://godbolt.org/z/GxdYrYYrj =3D=3D=3D=3D #include int main() { std::ispanstream a(""), b(""); a =3D std::move(b); } =3D=3D=3D=3D In file included from :1: /opt/compiler-explorer/gcc-trunk-20220114/include/c++/12.0.0/spanstream: In instantiation of 'std::basic_spanbuf<_CharT, _Traits>& std::basic_spanbuf<_CharT, _Traits>::operator=3D(std::basic_spanbuf<_CharT, _Traits>&&) [with _CharT =3D char; _Traits =3D std::char_traits]': /opt/compiler-explorer/gcc-trunk-20220114/include/c++/12.0.0/spanstream:258= :24: required from here /opt/compiler-explorer/gcc-trunk-20220114/include/c++/12.0.0/spanstream:89:= 7: error: base operand of '->' has non-pointer type 'std::basic_spanbuf' 89 | basic_spanbuf(std::move(__rhs))->swap(*this); | ^~~~~~~~~~~~~=