summaryrefslogtreecommitdiff
path: root/boost/serialization/singleton.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'boost/serialization/singleton.hpp')
-rw-r--r--boost/serialization/singleton.hpp26
1 files changed, 10 insertions, 16 deletions
diff --git a/boost/serialization/singleton.hpp b/boost/serialization/singleton.hpp
index db32395ce2..fcb79c3694 100644
--- a/boost/serialization/singleton.hpp
+++ b/boost/serialization/singleton.hpp
@@ -39,6 +39,10 @@
#include <boost/noncopyable.hpp>
#include <boost/serialization/force_include.hpp>
+#include <boost/archive/detail/auto_link_archive.hpp>
+#include <boost/serialization/config.hpp>
+#include <boost/archive/detail/abi_prefix.hpp> // must be the last header
+
#ifdef BOOST_MSVC
# pragma warning(push)
# pragma warning(disable : 4511 4512)
@@ -81,25 +85,15 @@ class BOOST_SYMBOL_VISIBLE singleton_module :
public boost::noncopyable
{
private:
- static bool & get_lock(){
- static bool lock = false;
- return lock;
- }
+ static bool & get_lock();
public:
-// static const void * get_module_handle(){
-// return static_cast<const void *>(get_module_handle);
-// }
- static void lock(){
- get_lock() = true;
- }
- static void unlock(){
- get_lock() = false;
- }
- static bool is_locked() {
- return get_lock();
- }
+ BOOST_SERIALIZATION_DECL static void lock();
+ BOOST_SERIALIZATION_DECL static void unlock();
+ BOOST_SERIALIZATION_DECL static bool is_locked();
};
+#include <boost/archive/detail/abi_suffix.hpp> // pops abi_suffix.hpp pragmas
+
namespace detail {
template<class T>