upgrade cereal
This commit is contained in:
@@ -48,7 +48,7 @@
|
||||
# define CEREAL_DLL_EXPORT __declspec(dllexport)
|
||||
# define CEREAL_USED
|
||||
#else // clang or gcc
|
||||
# define CEREAL_DLL_EXPORT
|
||||
# define CEREAL_DLL_EXPORT __attribute__ ((visibility("default")))
|
||||
# define CEREAL_USED __attribute__ ((__used__))
|
||||
#endif
|
||||
|
||||
@@ -67,13 +67,12 @@ namespace cereal
|
||||
class CEREAL_DLL_EXPORT StaticObject
|
||||
{
|
||||
private:
|
||||
//! Forces instantiation at pre-execution time
|
||||
static void instantiate( T const & ) {}
|
||||
|
||||
static T & create()
|
||||
{
|
||||
static T t;
|
||||
instantiate(instance);
|
||||
//! Forces instantiation at pre-execution time
|
||||
(void)instance;
|
||||
return t;
|
||||
}
|
||||
|
||||
@@ -95,6 +94,7 @@ namespace cereal
|
||||
std::unique_lock<std::mutex> lock;
|
||||
#else
|
||||
public:
|
||||
LockGuard(LockGuard const &) = default; // prevents implicit copy ctor warning
|
||||
~LockGuard() CEREAL_NOEXCEPT {} // prevents variable not used
|
||||
#endif
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user