It's not a constructor.
It's the destructor. It's the function that gets called when the object is destroyed, either by going out of scope or by having delete called on it.
It's for doing anything that needs doing when the object lifetime ends. For example, releasing resources.
You should never call it.
Last edited on
Thank you for the answers!:)