[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
oct file destructor?
From: |
Mike Miller |
Subject: |
oct file destructor? |
Date: |
Sun, 11 Feb 2018 23:48:13 -0800 |
User-agent: |
Mutt/1.9.3 (2018-01-21) |
Hi,
Is there a way to register a destructor to be called when an oct file is
unloaded (via "clear all" or "clear functions")? Does anyone have any
thoughts on how to implement such a thing or a good pattern to follow?
I was thinking of trying a class destructor of a static object as a
stand in, something like
struct cleanup_object
{
cleanup_object () {}
~cleanup_object () { uninitialize_something_important (); }
};
static cleanup_object obj;
Other suggestions? Thanks,
--
mike
signature.asc
Description: PGP signature
- oct file destructor?,
Mike Miller <=