4 ms·
Wouldn’t you wrap the allocation with an alloc/free function that does the allocation with whatever extra bytes that are needed? Letting the API users deal with
by spaetzleesser 6y ago
Wouldn’t you wrap the allocation with an alloc/free function that does the allocation with whatever extra bytes that are needed? Letting the API users deal with such details seems a recipe for disaster.
- zelly 6y agoBecause then you're forcing clients to use malloc rather than their own allocator
- spaetzleesser 6y agoGood point