[PATCH newlib] libc/include/malloc.h: Add prototype for GNU extension malloc_usable_size()

Mike Frysinger vapier@gentoo.org
Tue Mar 15 23:50:08 GMT 2022


On 15 Mar 2022 15:54, Joel Sherrill wrote:
> The prototype isn't wrapped by __GNU_VISIBLE. Should it be?

we're talking about malloc.h here.  this is already a non-standard header.
the standard malloc APIs are defined in stdlib.h:
https://pubs.opengroup.org/onlinepubs/9699919799/basedefs/stdlib.h.html

so i'm not sure how much value there is annotating standards in a header
that is not in any standard, and whose inclusion clearly declares "i am
not conforming to any standards".

we could put a disclaimer/explanation at the top of the header file to
make this a bit more clear.
-mike
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: not available
URL: <https://sourceware.org/pipermail/newlib/attachments/20220315/5a8cadfa/attachment-0001.sig>


More information about the Newlib mailing list