[C++-sig] eposing classes with protected destructors
David Abrahams
dave at boost-consulting.com
Mon Dec 23 06:25:31 CET 2002
"Daniel Paull" <dlp at fractaltechnologies.com> writes:
> BTW, I also added a template function to get my source to compile:
>
> namespace boost {
> template<class T> T * get_pointer( RefCountedObject<T> const& p )
> {
> return p.get();
> }
> }
>
> This should help anyone trying to reproduce the problem.
>
> Cheers,
>
> Daniel Paull
Daniel,
Unless your compiler doesn't support partial specialization, this
function template should be in the same namespace as RefCountedObject
so it can be found via argument-dependent lookup.
-Dave
--
David Abrahams
dave at boost-consulting.com * http://www.boost-consulting.com
Boost support, enhancements, training, and commercial distribution
More information about the Cplusplus-sig
mailing list