
20 Oct
2004
20 Oct
'04
8:22 p.m.
Colin Rafferty wrote:
Hi-
Shouldn't the constructor in intrusive_ptr be explicit?
explicit intrusive_ptr(T * p, bool add_ref = true): p_(p) { if(p_ != 0 && add_ref) intrusive_ptr_add_ref(p_); }
No, the constructor is implicit by design. Do you have a case where the implicit constructor causes problems?