From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 1062) id B00CA3858C2D; Thu, 12 May 2022 23:23:42 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org B00CA3858C2D Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable From: Alan Modra To: gdb-cvs@sourceware.org Subject: [binutils-gdb] gdb: remove use of PTR X-Act-Checkin: binutils-gdb X-Git-Author: Alan Modra X-Git-Refname: refs/heads/master X-Git-Oldrev: c8a9e88bf6ff32d90d082d07d3c5d12b938f8335 X-Git-Newrev: 903f7818e70ba7016d4b7d2d98c88446d5f40e71 Message-Id: <20220512232342.B00CA3858C2D@sourceware.org> Date: Thu, 12 May 2022 23:23:42 +0000 (GMT) X-BeenThere: gdb-cvs@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gdb-cvs mailing list List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 12 May 2022 23:23:42 -0000 https://sourceware.org/git/gitweb.cgi?p=3Dbinutils-gdb.git;h=3D903f7818e70b= a7016d4b7d2d98c88446d5f40e71 commit 903f7818e70ba7016d4b7d2d98c88446d5f40e71 Author: Alan Modra Date: Tue May 10 22:56:43 2022 +0930 gdb: remove use of PTR =20 PTR will disappear from ansidecl.h and libiberty on the next import from gcc. Remove current uses in gdb. Diff: --- gdb/alloc.c | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/gdb/alloc.c b/gdb/alloc.c index 60098c7b0c8..c6234e985be 100644 --- a/gdb/alloc.c +++ b/gdb/alloc.c @@ -44,10 +44,7 @@ consistent semantics and guard against typical memory management problems. */ =20 -/* NOTE: These are declared using PTR to ensure consistency with - "libiberty.h". xfree() is GDB local. */ - -PTR /* ARI: PTR */ +void * xmalloc (size_t size) { void *val; @@ -64,8 +61,8 @@ xmalloc (size_t size) return val; } =20 -PTR /* ARI: PTR */ -xrealloc (PTR ptr, size_t size) /* ARI: PTR */ +void * +xrealloc (void *ptr, size_t size) { void *val; =20 @@ -84,7 +81,7 @@ xrealloc (PTR ptr, size_t size) /* ARI: PTR */ return val; } =20 -PTR /* ARI: PTR */ +void * xcalloc (size_t number, size_t size) { void *mem;