3 ms·
> Unfortunately for some programmers (mainly coming from GC-aware languages), they just assume that it won't fail. In most GC languages I've used, if malloc fa
by rbanffy 5y ago
> Unfortunately for some programmers (mainly coming from GC-aware languages), they just assume that it won't fail.
In most GC languages I've used, if malloc fails for some reason (we rarely call it ourselves directly) an error happens and, unless handled, the whole app crashes. Which is fine, BTW, because I much prefer an app that crashes and dies to one that does things with the assumption something that didn't work did.