|
Boost : |
From: David Abrahams (dave_at_[hidden])
Date: 2006-03-29 22:16:30
"Peter Dimov" <pdimov_at_[hidden]> writes:
> David Abrahams wrote:
>
>>> On top of that there could be the friendlier: make_auto_ptr,
>>> make_shared_ptr, etc...
>>
>> None of that is particularly friendly compared to new_<T>(a,b,c)... as
>> long if we have the appropriate non-explicit converting constructor
>> from auto_ptr rvalues in all the other smart pointers.
>
> make_shared_ptr<T>( a, b, c ) (or however we end up calling it) still has
> the advantage of being able to fold the two allocations into one.
Very true; that's a good point.
-- Dave Abrahams Boost Consulting www.boost-consulting.com
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk