title: Detecting circular references with std::shared_ptr
body: <p>I am working with a lot of interfaces for the purposes of dependency injection (test driven development.) For this reason a lot of my objects are pointed to via std::shared_ptr. I would have used std::unique_ptr but they dont have a copy constructor as required when google mocking.</p>
  
  <p>What measures can I put in place with a view to early detection of circular references if they were to occur? </p>
  
  <p>I'm working on the linux platform with google test.</p>