When you finish working with an instance of another class, you should delete it to free up the resources that were used by the class. When a class instance is deleted, it calls the destructor, if the class has one defined.

delete object <ref>[no-error].

For more information, see DELETE-OBJECT statement.