Quantcast
Channel: How does "delete" reclaim memory? - Stack Overflow
Viewing all articles
Browse latest Browse all 4

How does "delete" reclaim memory?

$
0
0

I would like to concentrate on what happens when we say delete ptr. I know that a destructor of our class is called and then the amount of space new allocated is reclaimed.

If our object has other pointers etc, would that be reclaimed as well or is it up to the definition of our constructor to do so?


Viewing all articles
Browse latest Browse all 4

Trending Articles





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