Am 01.09.25 um 18:27 schrieb Maarten Brock:
But according to this link you posted earlier, every other system except
BSD does
the same as SDCC currently does:
https://www.open-std.org/jtc1/sc22/wg14/www/docs/n2464.pdf
Mostly, though it misses some details:
* glibc is kind of worst, since there, malloc(0) allocates memory, but
realloc(ptr, 0) doesn't, so it looks inconsistent to me.
* musl libc does not free on realloc(ptr, 0).
* The BSDs by now also have diverged a bit. FreeBSD does free on
realloc(ptr, 0), but OpenBSD and NetBSD don't.
* macOS behaves like what I want SDCC to change to.
Philipp
_______________________________________________
Sdcc-user mailing list
Sdcc-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sdcc-user