Boost logo

Boost :

From: Andrei Alexandrescu (andrewalex_at_[hidden])
Date: 2002-01-07 14:58:32


> Another thing that I wanted to remark is that having SmartPtr to be
> inherited from PlicyAdaptor ( or separate policies like in MC++D ) is
> brealing encapsulation.

If practical experience is of any relevance:

* Users complained about SmartPtr being bigger than it ought to. That is due
to multiple inheritance. If I understand correctly, a compiler is not
allowed to appy EBO to all base classes in a multiple-inheritance scheme. A
single inheritance solution with nested templates would avoid this problem.

* Users did not complain about SmartPtr being limited, unnecessarily
complex, hard to use, or not validating their designs.

Andrei


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk