
[Loïc Joly]
I was wondering if this is just a stylistic choice, or if there are some differences?
Unless I'm missing something, it's purely stylistic: * make_shared<T>() is less typing (with less punctuation) than shared_ptr<T>::make(). * What would you call allocate_shared<T>()? * It is similar to make_pair()/make_tuple(), although different in effect. The notable thing is that C++0x lacks make_unique<T>(), which it should really have. [Max Sobolev]
free functions are preferable due to decreasing code coupling:
Actually, make_shared<T>() needs access to shared_ptr's guts, at least if the implementer takes advantage of the obvious and highly desirable optimization. They are tightly coupled to begin with. Stephan T. Lavavej Visual C++ Libraries Developer (I obviously didn't design make_shared<T>(), but I have implemented it.)