Alloc functions cleanup
Various minor cleanup for the allocation functions in stdlib
, including:
- Avoid variable shadowing in
realloc()
(more readable) - Use built-in
is_power_of_two()
inmemalign()
- Skip
errno::
prefix, the values are in scope - Add size-0 tests for alloc functions
- Fix memory leaks (missing
free()
) for some of the tests