
22 Feb
2009
22 Feb
'09
10:11 p.m.
Alexader wrote:
But there already is a way to escape the scope, via swap().
How ? I thought scoped_ptr was to prohibit swap either.
_______________________________________________ Boost-users mailing list Boost-users@lists.boost.org http://lists.boost.org/mailman/listinfo.cgi/boost-users
WFM... void foo(scoped_array<int> &b) { scoped_array<int> a(new int[5]); swap(a,b); // escape } -- Yang Zhang http://www.mit.edu/~y_z/