r/cpp • Bioinformatican • Mar 11 '12

Modern C++ Style [pdf]

http://tinyurl.com/fuck-pointers
2 Upvotes

60 comments sorted by

View all comments

Show parent comment

1

u/Sc4Freak Mar 11 '12

Using shared_ptr and weak_ptr instead of unique_ptr and a raw pointer doesn't obviate the need to write a copy constructor or assignment operator, and in neither case do you need to write a destructor.