&gt;  I&#x27;m pretty sure that everything that can be done by a GC can be done by `shared_ptr` and `weak_ptr`. If not, then you can use Boehm GC if you don&#x27;t do anything weird with pointers.<p>Except only slower and subject to thread races.