From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id D99603840C39; Sat, 9 May 2020 20:27:26 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org D99603840C39 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1589056046; bh=C7LcdzmbPJdqZ4+6BDnJX789C6ToNibiSUG05F1nZj0=; h=From:To:Subject:Date:In-Reply-To:References:From; b=RhJuRlZgsuVvKQKw70oVN1cEiy3tRLLcAsaa9HvzJwKyJOGT1Us/eT7CmUCYTyRKO jOb48f4pa+AJDoW/k3cDwH/GtY7i6AD/U27CKu00k4lYFFs7xccnddDrjRLnGuMXJ8 q7xZCT+MGl5Vd2VCyKr/KhkZlhWFPYgdr92jgayo= From: "dcb314 at hotmail dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/80711] warn on non-const accessor member functions Date: Sat, 09 May 2020 20:27:26 +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: 7.0 X-Bugzilla-Keywords: diagnostic X-Bugzilla-Severity: enhancement X-Bugzilla-Who: dcb314 at hotmail 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 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: Sat, 09 May 2020 20:27:27 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D80711 --- Comment #10 from David Binderman --- (In reply to Jonathan Wakely from comment #9) > (In reply to David Binderman from comment #8) > > My opinion is that a first approximation at implementation in gcc would > > merely look for C++ member functions that are return statements only. > > More fancy things could be done later in a second version. >=20 > No, that won't work: Of course. Some false positives are to be expected with a first approximation. Perhaps I've been slightly less than clear.=20 A first approximation isn't the final solution. It should be a step towards a final solution.=