From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 852A839730EC; Wed, 20 Jan 2021 17:00:46 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 852A839730EC From: "foss at grueninger dot de" To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/98753] -Wfree-nonheap-object on Bison generated code Date: Wed, 20 Jan 2021 17:00:46 +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: foss at grueninger dot de 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: 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: Wed, 20 Jan 2021 17:00:46 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D98753 --- Comment #6 from Christoph --- Sorry for not providing the command line argument and the new output. > gcc-11 -std=3Dc++17 cmCommandArgumentParser_complete.cxx=20 cmCommandArgumentParser.cxx: In function =E2=80=98int cmCommandArgument_yyparse(yyscan_t)=E2=80=99: cmCommandArgumentParser.cxx:1838:10: warning: =E2=80=98void free(void*)=E2= =80=99 called on unallocated object =E2=80=98yyssa=E2=80=99 [-Wfree-nonheap-object] cmCommandArgumentParser.cxx:1203:16: note: declared here /usr/lib64/gcc/x86_64-suse-linux/11/../../../../x86_64-suse-linux/bin/ld: /usr/lib64/gcc/x86_64-suse-linux/11/../../../../lib64/crt1.o: in function `_start': /home/abuild/rpmbuild/BUILD/glibc-2.26/csu/../sysdeps/x86_64/start.S:110: undefined reference to `main' ...=