*_ptr.hpp:

- Added detail::is_pointerlike_helper function templates for Signals

weak_ptr.hpp:
  - Added get_pointer function template for weak_ptr


[SVN r15099]
This commit is contained in:
Douglas Gregor
2002-08-26 15:27:23 +00:00
parent e84eb3f1ba
commit b9dceb2340
4 changed files with 32 additions and 0 deletions
+7
View File
@@ -25,6 +25,7 @@
#include <boost/checked_delete.hpp>
#include <boost/throw_exception.hpp>
#include <boost/detail/shared_count.hpp>
#include <boost/type_traits/ice.hpp>
#include <memory> // for std::auto_ptr
#include <algorithm> // for std::swap
@@ -323,6 +324,12 @@ template<typename T> inline T * get_pointer(shared_ptr<T> const & p)
return p.get();
}
namespace detail {
// is_pointerlike_helper enables Signals library to recognize shared_ptr
template<typename T>
type_traits::yes_type is_pointerlike_helper(const shared_ptr<T>&, int);
} // end namespace detail
// shared_from_this() creates a shared_ptr from a raw pointer (usually 'this')
namespace detail