The following code gives a compilation error in VS2010, which support shared_ptr and make_shared function. Why and how to correct it?
#include <memory>
class A
{
A(std::shared_ptr<int> p = std::make_shared<int>()) // error is at this line
{}
};
It shows "make_shared" is not a member of "global namespace".