summaryrefslogtreecommitdiff
path: root/boost/interprocess/smart_ptr/intrusive_ptr.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'boost/interprocess/smart_ptr/intrusive_ptr.hpp')
-rw-r--r--boost/interprocess/smart_ptr/intrusive_ptr.hpp24
1 files changed, 14 insertions, 10 deletions
diff --git a/boost/interprocess/smart_ptr/intrusive_ptr.hpp b/boost/interprocess/smart_ptr/intrusive_ptr.hpp
index f6d5c8b..ff66512 100644
--- a/boost/interprocess/smart_ptr/intrusive_ptr.hpp
+++ b/boost/interprocess/smart_ptr/intrusive_ptr.hpp
@@ -3,7 +3,7 @@
// This file is the adaptation for Interprocess of boost/intrusive_ptr.hpp
//
// (C) Copyright Peter Dimov 2001, 2002
-// (C) Copyright Ion Gaztanaga 2006. Distributed under the Boost
+// (C) Copyright Ion Gaztanaga 2006-2012. Distributed under the Boost
// Software License, Version 1.0. (See accompanying file
// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
//
@@ -14,6 +14,10 @@
#ifndef BOOST_INTERPROCESS_INTRUSIVE_PTR_HPP_INCLUDED
#define BOOST_INTERPROCESS_INTRUSIVE_PTR_HPP_INCLUDED
+#if defined(_MSC_VER)
+# pragma once
+#endif
+
//!\file
//!Describes an intrusive ownership pointer.
@@ -56,12 +60,12 @@ class intrusive_ptr
//!Provides the type of the stored pointer.
typedef T element_type;
- /// @cond
+ #if !defined(BOOST_INTERPROCESS_DOXYGEN_INVOKED)
private:
typedef VoidPointer VP;
typedef intrusive_ptr this_type;
typedef pointer this_type::*unspecified_bool_type;
- /// @endcond
+ #endif //#ifndef BOOST_INTERPROCESS_DOXYGEN_INVOKED
public:
//!Constructor. Initializes internal pointer to 0.
@@ -125,7 +129,7 @@ class intrusive_ptr
this_type(rhs).swap(*this);
return *this;
}
-
+
//!Returns a reference to the internal pointer.
//!Does not throw
pointer &get()
@@ -166,10 +170,10 @@ class intrusive_ptr
void swap(intrusive_ptr & rhs)
{ ipcdetail::do_swap(m_ptr, rhs.m_ptr); }
- /// @cond
+ #if !defined(BOOST_INTERPROCESS_DOXYGEN_INVOKED)
private:
pointer m_ptr;
- /// @endcond
+ #endif //#ifndef BOOST_INTERPROCESS_DOXYGEN_INVOKED
};
//!Returns a.get() == b.get().
@@ -219,9 +223,9 @@ bool operator!=(const typename intrusive_ptr<T, VP>::pointer &a,
template<class T, class VP> inline
bool operator<(intrusive_ptr<T, VP> const & a,
intrusive_ptr<T, VP> const & b)
-{
+{
return std::less<typename intrusive_ptr<T, VP>::pointer>()
- (a.get(), b.get());
+ (a.get(), b.get());
}
//!Exchanges the contents of the two intrusive_ptrs.
@@ -277,7 +281,7 @@ inline boost::interprocess::intrusive_ptr<T, VP>reinterpret_pointer_cast
} // namespace interprocess
-/// @cond
+#if !defined(BOOST_INTERPROCESS_DOXYGEN_INVOKED)
#if defined(_MSC_VER) && (_MSC_VER < 1400)
//!Returns p.get().
@@ -287,7 +291,7 @@ inline T *to_raw_pointer(boost::interprocess::intrusive_ptr<T, VP> p)
{ return p.get(); }
#endif
-/// @endcond
+#endif //#ifndef BOOST_INTERPROCESS_DOXYGEN_INVOKED
} // namespace boost