blocxx
LazyGlobal.hpp File Reference
#include "blocxx/BLOCXX_config.h"
#include "blocxx/ThreadOnce.hpp"
#include "blocxx/GlobalPtr.hpp"

Go to the source code of this file.

Classes

struct  BLOCXX_NAMESPACE::DefaultVariableConstructorFactory< T, PODType >
 
class  BLOCXX_NAMESPACE::LazyGlobal< T, PODType, FactoryT >
 This class can be used to store a global variable that is lazily initialized in a thread safe manner. More...
 
struct  BLOCXX_NAMESPACE::LazyGlobal< T, PODType, FactoryT >::InitPtr
 

Namespaces

namespace  BLOCXX_NAMESPACE
 Taken from RFC 1321.
 

Macros

#define BLOCXX_LAZY_GLOBAL_INIT(...)
 Statically initialize a LazyGlobal instance.
 

Macro Definition Documentation

◆ BLOCXX_LAZY_GLOBAL_INIT

#define BLOCXX_LAZY_GLOBAL_INIT ( ...)
Value:
{ __VA_ARGS__, 0, BLOCXX_ONCE_INIT }

Statically initialize a LazyGlobal instance.

Parameters
StaticPOD data convertible to type T. Take care that this is not a function or constructor.

Definition at line 188 of file LazyGlobal.hpp.