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
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment