Go to the documentation of this file.
    9 #error "This is shit, do not include pls"; 
   25 #define DECLARE_SINGLETON(CLASSNAME) \ 
   28     static CLASSNAME* instance(); \ 
   29     static void destroy(); \ 
   36     static CLASSNAME* _instance; 
   54 #define DEFINE_SINGLETON(CLASSNAME) \ 
   55     CLASSNAME* CLASSNAME::_instance = nullptr; \ 
   57     CLASSNAME* CLASSNAME::instance() \ 
   61             _instance = new CLASSNAME; \ 
   66     void CLASSNAME::destroy() \ 
   69         _instance = nullptr; \