Completion of error handling
Would you like to add more error handling for return values from functions like the following?
If malloc actually failed we are looking at a catastrophic error. Should an assert suffice?
Also I was considering the concept of exposing alloc/free via allocator interfaces so that malloc is not directly exposed. This allows the embedder to provide an alternate memory manager if need be. How do you feel about that?
I do not like the macro "assert" for the mentioned use case here because corresponding checks will be omitted again if the preprocessor symbol "NDEBUG" would be defined.
How do you think about to improve static source code analysis also for your software?
How would another memory manager help here?