Search code examples
c++memory-managementcautoptr

Does the CAutoPtr class implement reference counting?


Modern ATL/MFC applications now have access to a new shared pointer class called CAutoPtr, and associated containers (CAutoPtrArray, CAutoPtrList, etc.).

Does the CAutoPtr class implement reference counting?


Solution

  • Having checked the CAutoPtr source, no, reference counting is not supported. Using boost::shared_ptr instead if this ability is required.