Boost logo

Boost :

From: Daniel Frey (d.frey_at_[hidden])
Date: 2008-04-09 14:07:02

On Wed, 2008-04-09 at 13:47 -0400, Frank Mori Hess wrote:
> On Wednesday 09 April 2008 11:13 am, Daniel Frey wrote:
> > I have use cases which would be a lot easier to implement if
> > shared_from_this() never throws. And - at least with the "old"
> > implementation - I don't see any reason why this guarantee should not
> > hold. Of course it's not a defect, but to me it seems desirable.
> It is technically possible to make it throw without violating the functions
> documented requirements, if there are multiple owners. For example, if pass
> the raw pointer to multiple shared_ptrs with null deleters.

Could you provide a small but complete code example, please? I fail to
see how that case should be legal.

Regards, Daniel

Boost list run by bdawes at, gregod at, cpdaniel at, john at