diff options
author | maximius <none@none> | 2009-10-17 15:51:44 -0700 |
---|---|---|
committer | maximius <none@none> | 2009-10-17 15:51:44 -0700 |
commit | e585187b248f48b3c6e9247b49fa07c6565d65e5 (patch) | |
tree | 637c5b7ddacf41040bef4ea4f75a97da64c6a9bc /src/framework/Policies/ObjectLifeTime.h | |
parent | 26b5e033ffde3d161382fc9addbfa99738379641 (diff) |
*Backed out changeset 3be01fb200a5
--HG--
branch : trunk
Diffstat (limited to 'src/framework/Policies/ObjectLifeTime.h')
-rw-r--r-- | src/framework/Policies/ObjectLifeTime.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/framework/Policies/ObjectLifeTime.h b/src/framework/Policies/ObjectLifeTime.h index 51765d4d4b4..86303f889fb 100644 --- a/src/framework/Policies/ObjectLifeTime.h +++ b/src/framework/Policies/ObjectLifeTime.h @@ -17,14 +17,19 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ + #ifndef TRINITY_OBJECTLIFETIME_H #define TRINITY_OBJECTLIFETIME_H + #include <stdexcept> #include "Platform/Define.h" + typedef void (* Destroyer)(void); + namespace Trinity { void TRINITY_DLL_SPEC at_exit( void (*func)() ); + template <class T> class TRINITY_DLL_DECL ObjectLifeTime { @@ -33,8 +38,11 @@ namespace Trinity { at_exit( destroyer ); } + DECLSPEC_NORETURN static void OnDeadReference(void) ATTR_NORETURN; + }; + template <class T> void ObjectLifeTime<T>::OnDeadReference(void) // We don't handle Dead Reference for now { |