enable_shared_from_this: boost vs. std

If you are a modern C++ developer, then you are probably using some kind of smart pointer implementation. The boost C++ libraries offer one possible solution (among many other useful features) and are generally held in high regards in the C++ community. With the latest C++11 standard, some of those ideas found their way into the standard library bundled with your C++ compiler. At some point, you very likely run into a situation where you need a shared_ptr of one of your classes, but only have a raw pointer or this available.

This is where enable_shared_from_this comes in. Boost and the standard C++ library provide this feature and they both have a very important prerequisite for this to work.
Read More »