From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id E60ED3861012; Tue, 19 Jan 2021 20:55:37 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org E60ED3861012 From: "msebor at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/98753] -Wfree-nonheap-object on Bison generated code Date: Tue, 19 Jan 2021 20:55:37 +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: 11.0 X-Bugzilla-Keywords: diagnostic X-Bugzilla-Severity: normal X-Bugzilla-Who: msebor at gcc dot gnu.org X-Bugzilla-Status: WAITING 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_status cf_reconfirmed_on everconfirmed cc 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: Tue, 19 Jan 2021 20:55:38 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D98753 Martin Sebor changed: What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |WAITING Last reconfirmed| |2021-01-19 Ever confirmed|0 |1 CC| |msebor at gcc dot gnu.org --- Comment #1 from Martin Sebor --- The attached file depends on a number of headers. To reproduce a problem we need a standalone test case that can be compiled on its own. One way to do that is to use the -E option to GCC to obtain the translation unit and attaching that. That said, based on the description I suspect the warning is a false positi= ve with the same root cause as pr54202. Until a better solution is available = in GCC the workaround is to suppress the warning, either by #pragma GCC diagnostic, or by using -Wno-free-nonheap-object on the command line.=