I want to use boost::log at some point, but I cannot pass a std::shared_ptr as a parameter, because the compiler (VS2010) cannot convert it into a boost::shared_ptr.
I don’t really like the fact that they are aliens to one another.
Is there a safe and transparent way to convert one into the another, so as they don’t stumble over each other?
I don’t think it is duplicate of this question that states both are the same.
You could do it like this:
EDIT: Note that this does not work with weak references to the source ptr. So be careful with those!