4 ms·
Like I said, it teaches the basics. There's a single page on heap vs stack allocation and it says malloc allocates memory to the heap. That's it. That's all you
by ScottFree 7y ago
Like I said, it teaches the basics. There's a single page on heap vs stack allocation and it says malloc allocates memory to the heap. That's it. That's all you really need to know to do stuff and it doesn't go into what malloc actually does under the hood.
Modern C has an entire chapter called "malloc and friends" where it goes into much more depth about malloc, calloc, realloc, etc.
The book is a good introduction to programming in C and I'm glad I read it. You obviously have a history with the author and I'll thank you to keep your past impressions out of this particular discussion.
- tom_mellior 7y ago> There's a single page on heap vs stack allocation and it says malloc allocates memory to the heap. That's it. That's all you really need to know to do stuff Every other C book seems to disagree, but OK. Does the book cover the -> operator? Does it mention free and realloc? You need those to do stuff, at least. > You obviously have a history with the author How is this obvious, since it is incorrect?
- ScottFree 7y agoI'm not interested in continuing this line of conversation. Read the book if you want to know more.