On Monday 27 January 2003 08:26 pm, David B. Held wrote:
>     My understanding is that the template constructor:
>
>         template
>         <
>             typename T1,
>             template <class> class OP1,
>             class CP1,
>             template <class> class KP1,
>             template <class> class SP1
>
>         SmartPtr(SmartPtr<T1, OP1, CP1, KP1, SP1> const& rhs)
>
>     is going to somehow get in the way by "eating" everything,
>     and in particular not allow the constructor:
>
>         SmartPtr(ByRef<SmartPtr> rhs)
>
>     to kick in, as it should.

*sniff* *sniff* Smells like enable_if:

template
<
  typename T1,
  template <class> class OP1,
  class CP1,
  template <class> class KP1,
  template <class> class SP1
>
SmartPtr(SmartPtr<T1, OP1, CP1, KP1, SP1> const& rhs,
              typename SmartPtr<T1, OP1, CP1, KP1, SP1>::copyable* = 0)

In SmartPtrs are should be copyable, include 
  typedef void copyable;

In other SmartPtrs, don't include typedef copyable.

        Doug
_______________________________________________
Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost

Reply via email to