
20 Mar
2005
20 Mar
'05
1:41 p.m.
Thorsten Ottosen wrote:
Hi,
I need some kind of traits for my indirect_fun class if it should be usable with smart pointers.
I imagined some like
template< class T > struct pointer_value { typedef BOOST_DEDUCED_TYPENAME remove_pointer<T>::type type; };
template< class T, class D > struct pointer_value< shared_ptr<T,D> > { typedef T type; };
etc.
Any thoughts?
<boost/pointee.hpp>, one of the many undocumented Boost headers. :-)