if (ClassName->can('DESTROY') { *ClassName::OLD_DESTROY = \&ClassName::DESTROY; *ClassName::DESTROY = sub { cleanup_object($_[0]); goto &$_[0]->DESTROY; } } else { *ClassName::DESTROY = \&cleanup_object($_[0]); } #### -- Joost downtime n. The period during which a system is error-free and immune from user input.