From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id E17133858C98; Mon, 18 Mar 2024 06:50:44 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org E17133858C98 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1710744644; bh=DcY6hK1H3N2vLtYpuoNNTnuvS8N1SC45OsAJzHX76G0=; h=From:To:Subject:Date:In-Reply-To:References:From; b=gwYWBBOe23LeEcdIAUVs8lo8YNmABrzu4CUMdNm07tH5H+JuMrsIvCMXBRaDn79O0 VAg9jdrLlvtf2RvwotzQO9p6mVbaame95PxKtTDVPqC1pmq+KraiPgIrBdAmmY9hZz lK6M3n38ubJhEgc/eOHyDfGKkbfo8VoW5IM4JfRE= From: "redi at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/36587] Feature: add warning for constructor call with discarded return. Date: Mon, 18 Mar 2024 06:50:44 +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: 4.1.1 X-Bugzilla-Keywords: diagnostic X-Bugzilla-Severity: enhancement X-Bugzilla-Who: redi at gcc dot gnu.org X-Bugzilla-Status: RESOLVED X-Bugzilla-Resolution: FIXED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: 7.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 List-Id: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D36587 --- Comment #17 from Jonathan Wakely --- No, the nodiscard warnings must be silenced with a cast to void. They can't= be "stronger" than that.=