Quantcast
Channel: Pointers and dynamic memory
Viewing all articles
Browse latest Browse all 4

Pointers and dynamic memory

$
0
0
So, how does the system know to release that memory?

If I did this:

MyClass class;

That memory is created on the stack and will be released when the function returns, right? Does the OS assign some kind of process ID when it allocates dynamic memory on the heap to know when that PID exits to release all of its memory from the heap?

Viewing all articles
Browse latest Browse all 4

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>