Wednesday, September 1, 2010

auto_ptr

It is not okay to pass auto_ptrs as references.

Reference: The C++ Standard Library: A Tutorial and Reference by Nicolai M. Josuttis. Addison-Wesley, 1999, p. 43.

See also the following link for some reasons why:
http://nicoletti.50megs.com/cpp_notes/auto_ptr/pass.html

No comments:

Post a Comment