HyperspaceExplorer 0.7.1
|
Implementation of the CreationPolicy used by SingletonHolder Creates an object in static memory Implementation is slightly nonportable because it uses the MaxAlign trick (an union of all types to ensure proper memory alignment). This trick is nonportable in theory but highly portable in practice. More...
#include <SingletonHolder.h>
Classes | |
union | MaxAlign |
Auxiliary class to find the maximum alignment size. More... | |
Static Public Member Functions | |
static T * | Create () |
create managed object | |
static void | Destroy (T *p) |
destroy managed object |
Implementation of the CreationPolicy used by SingletonHolder Creates an object in static memory Implementation is slightly nonportable because it uses the MaxAlign trick (an union of all types to ensure proper memory alignment). This trick is nonportable in theory but highly portable in practice.