From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 10A823858415; Thu, 3 Feb 2022 21:34:31 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 10A823858415 From: "gcc_bugzilla at axeitado dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug libstdc++/102994] std::atomic::wait is not marked const Date: Thu, 03 Feb 2022 21:34: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: 11.2.0 X-Bugzilla-Keywords: rejects-valid X-Bugzilla-Severity: normal X-Bugzilla-Who: gcc_bugzilla at axeitado dot com X-Bugzilla-Status: REOPENED X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: rodgertq at gcc dot gnu.org X-Bugzilla-Target-Milestone: 11.3 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: Thu, 03 Feb 2022 21:34:31 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D102994 --- Comment #6 from =C3=93scar Fuentes -= -- (In reply to Jonathan Wakely from comment #5) > (In reply to =C3=93scar Fuentes from comment #4) > > The fix is wrong. It changes atomic_notify_one and atomic_notify_all in= stead > > of atomic<>::wait. >=20 > It changed both. >=20 > > So right now atomic<>::wait remains unfixed >=20 > Are you sure? Sigh. Sorry. It would be nice if the commit message mentioned the change to atomic_notify_* and its motivation, though. > > and atomic_notify_(one|all) arg > > is wrongly marked as const. >=20 > This will be the subject of a library issue, potentially fixing the > standard. The notify functions should be const too. So IIUC you are applying modifications to libstdc++ that deviate from the published standard expecting that the committee will accept those changes. = As a user, this is troublesome, because right now I need to special-case gcc ver= sion >11.2 and maybe version