This commit is contained in:
2026-04-22 19:36:06 +08:00
commit bb062ecfb4
370 changed files with 291868 additions and 0 deletions

15
include/Singleton.h Normal file
View File

@@ -0,0 +1,15 @@
#ifndef __SINGLETON_H__RINDRO_
#define __SINGLETON_H__RINDRO_
//饿汉模式
#define RINDRO_SINGLETON_DEFINE_S(TypeName) \
static TypeName *Get() \
{ \
static TypeName type_rindro_instance; \
return &type_rindro_instance; \
} \
\
TypeName(const TypeName &) = delete; \
TypeName &operator=(const TypeName &) = delete
#endif // __SINGLETON_H__