Boost logo

Boost :

From: David Abrahams (david.abrahams_at_[hidden])
Date: 2002-06-18 08:10:47

----- Original Message -----
From: "Yitzhak Sapir" <yitzhaks_at_[hidden]>

> If this is part of a constructor initializer list, I believe (but am not
> that the release() function won't be evaluated until the member is to be
> initialized.

Why speculate? Look it up.

> So there won't be any throwing functions being called between release()
and the
> constructor of scoped_ptr.

You just said you were speculating about it, so it's hard to take the above
sentence seriously.

> I'm not sure what you mean about multiple arguments, but I assume you
mean that if I do something like:
> class A { A(param1, param2, param3); }
> and then do:
> A(x, y.release(), z);
> then y.release() breaks the ownership management until the constructor of
A takes it over, in which case an exception may be thrown in between.


> But I think this would be true regardless of whether the constructor of
scoped_ptr takes an auto_ptr or not.

No. Sorry to be so terse about it, but I don't know what else to say.


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